Documentation fails to generate via NPM scrips on Windows
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 768
- Forks
- 191
- PR merge metrics
- No merged PRs in 30d
Description
The `package.json` scrips `document-services`, `document-classes`, `document` and `precommit` fail to run on Windows due to the `documentation.js` errors:
```
Table of contents defined sorting of MapiRequest but no documentation with that namepath was found
Table of contents defined sorting of MapiResponse but no documentation with that namepath was found
Table of contents defined sorting of MapiError but no documentation with that namepath was found
Table of contents defined sorting of MapiClient but no documentation with that namepath was found
Table of contents defined sorting of Styles but no documentation with that namepath was found
Table of contents defined sorting of Static but no documentation with that namepath was found
....
Error: README.md
115:31-115:100 warning Link to unknown heading in `docs/classes.md`: `mapirequest` missing-heading-in-file remark-validate-links
163:31-163:102 warning Link to unknown heading in `docs/classes.md`: `mapiresponse` missing-heading-in-file remark-validate-links
204:31-204:96 warning Link to unknown heading in `docs/classes.md`: `mapierror` missing-heading-in-file remark-validate-links
‼ 3 warnings
at Function.module.exports.sync (C:\Projects\@mapbox\mapbox-sdk-js\node_modules\remark-preset-davidtheclark\node_modules\execa\index.js:303:26)
at Object. (C:\Projects\@mapbox\mapbox-sdk-js\node_modules\remark-preset-davidtheclark\bin.js:12:22)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
at startup (internal/bootstrap/node.js:236:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:560:3)
```
This also prevents a `git commit` due to the failing `precommit` script. I had to commit with `--no-verify` in order to proceed.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the package.json scripts document-services, document-classes, document, and precommit, then reproduce the documentation.js errors on Windows. Inspect the README.md links and docs/classes.md headings mentioned in the output; done means documentation generation and the precommit script complete without these errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- build-system, documentation
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100