Skip to content

@component: Bad character escape sequence error on windows 10 #43

@fhenderson

Description

@fhenderson

When I add the tag @component in a React functional component description header and I ran the documentation generation I am getting the following error. Any idea of how the generated PATH got inserted \ in it

D:\git\nirvana\ui>yarn docs
yarn run v1.17.3
$ jsdoc -c jsdoc.conf.json
Generating entry file for "components" plugin
Bundling components
running: parcel build docs/entry.js --out-dir docs/build
×  D:\git\nirvana\ui\docs\entry.js:12:54: Bad character escape sequence (12:54)
  10 |
  11 |
> 12 |       import ReactWrapper from '../../D:\git\nirvana\ui\node_modules\better-docs/lib/react-wrapper.js';
     |                                                      ^
  13 |
  14 |       window.React = React;
  15 |

D:\git\nirvana\ui\node_modules\better-docs\bundler.js:83
    throw error
    ^

Error: Command failed: parcel build docs/entry.js --out-dir docs/build
    at checkExecSyncError (child_process.js:629:11)
    at execSync (child_process.js:666:13)
    at bundle (D:\git\nirvana\ui\node_modules\better-docs\bundler.js:78:5)
    at Object.exports.publish (D:\git\nirvana\ui\node_modules\better-docs\publish.js:655:5)
    at Object.module.exports.cli.generateDocs (D:\git\nirvana\ui\node_modules\jsdoc\cli.js:441:39)
    at Object.module.exports.cli.processParseResults (D:\git\nirvana\ui\node_modules\jsdoc\cli.js:392:24)
    at module.exports.cli.main (D:\git\nirvana\ui\node_modules\jsdoc\cli.js:235:18)
    at Object.module.exports.cli.runCommand.cb [as runCommand] (D:\git\nirvana\ui\node_modules\jsdoc\cli.js:186:9)
    at D:\git\nirvana\ui\node_modules\jsdoc\jsdoc.js:93:9
    at Object.<anonymous> (D:\git\nirvana\ui\node_modules\jsdoc\jsdoc.js:94:3)
    at Module._compile (internal/modules/cjs/loader.js:776:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
    at Module.load (internal/modules/cjs/loader.js:653:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
    at Function.Module._load (internal/modules/cjs/loader.js:585:3)
    at Function.Module.runMain (internal/modules/cjs/loader.js:829:12)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions