nodejs.dev
nodejs.dev copied to clipboard
Git actions linting failed while local linting is success.
Summary
I use npm run lint
and there is no error but the git actions CI shows there are format problems, this makes me unable to use npm run lint --fix
to auto fix the problems.
Also, looks like linting in code examples now requires semicolons but most of the original examples don't use semicolons, would this makes the tutorials inconsistent?


Hi @clean99, could you please provide link to repo with failed CI?
Hi @clean99, could you please provide link to repo with failed CI?
Hi @rodion-arr, thanks for replying to me, you can check this git actions and commit(and previously commits) correspondingly.
I assume it's related to #2092 - linter checks JS code blocks in markdown that was changed in your branch, not sure why they wasn't listed in original PR
I assume it's related to #2092 - linter checks JS code blocks in markdown that was changed in your branch, not sure why they wasn't listed in original PR
OK, I see~ but would it be better to keep the format in markdown the same? Now if I add new examples in docs, the docs will somewhere use semicolons and some don't.
OK, I see~ but would it be better to keep the format in markdown the same? Now if I add new examples in docs, the docs will somewhere use semicolons and some don't.
Yup, but I believe this was addressed already. By running eslint . --fix
it would apply the same ESLint configuration across the charter. Or do you still have examples of inconsistencies?
I discovered that in some OSs the lack of "
(quotes) around some lining commands would result in unexpected behaviours.
For example, the glob command was not recognised equally on Windows and macOS for the stylelint and eslint commands. I fixed this.
Closing this issue as it seems fixed, but Author is free to reopen it if necessary.