Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lint: run prettier on all doc files #512

Closed
jorgeorpinel opened this issue Jul 31, 2019 · 15 comments · Fixed by #523
Closed

lint: run prettier on all doc files #512

jorgeorpinel opened this issue Jul 31, 2019 · 15 comments · Fixed by #523
Labels
p1-important Active priorities to deal within next sprints 🐛 type: bug Something isn't working. website: eng-doc DEPRECATED JS engine for /doc

Comments

@jorgeorpinel
Copy link
Contributor

jorgeorpinel commented Jul 31, 2019

See #512 (comment)


A problem after implementing #372 seems to be that pretty-quick is that some lines inside md fenced code blocks, the ones starting with -, seem to be confused for bullets, and thus indented. E.g. everything starting at path would be indented in the sample below (from static/docs/user-guide/external-dependencies.md):

image

The linter should simply ignore code blocks 🙂 OK'd by Ivan in #512 (comment)

@jorgeorpinel

This comment has been minimized.

@jorgeorpinel jorgeorpinel added the 🐛 type: bug Something isn't working. label Jul 31, 2019
@shcheklein shcheklein added p1-important Active priorities to deal within next sprints website: eng-doc DEPRECATED JS engine for /doc labels Jul 31, 2019
@algomaster99

This comment has been minimized.

@jorgeorpinel

This comment has been minimized.

@algomaster99

This comment has been minimized.

@jorgeorpinel
Copy link
Contributor Author

Just change anything in static/docs/commands-reference/import-url.md (outside of YAML code blocks) and try to git commit your change. It will indent parts of the YAML code block contents:

Screen Recording 2019-08-04 at 01 59 50 2019-08-04 02_08_11

p.s. creating this gif took a long time. What did you make them with again? Thanks

@algomaster99

This comment has been minimized.

@jorgeorpinel

This comment has been minimized.

@algomaster99

This comment has been minimized.

@jorgeorpinel

This comment has been minimized.

@shcheklein
Copy link
Member

@jorgeorpinel I think it's fine if it's hard to fix it and if YAML is valid.

@jorgeorpinel
Copy link
Contributor Author

jorgeorpinel commented Aug 7, 2019

Yeah I guess if it can't be fixed with our current linter its better to let it indent those locks instead of having to add a bunch of <!-- prettier-ignore -->s.

BTW weren't we going to run prettier on all the docs? I don't think we ever did that @algomaster99 would you like to try it? And open a PR that closes this issue (notice changed title) if successful 🙂

@jorgeorpinel jorgeorpinel changed the title lint: don't indent fenced code block contents lint: run prettier on all doc files Aug 7, 2019
@algomaster99
Copy link
Contributor

@jorgeorpinel I might have done this here. Let me run it again and find if there are changes or not.

@shcheklein
Copy link
Member

@algomaster99 should we run it for docs as well once again like @jorgeorpinel suggested?

@jorgeorpinel
Copy link
Contributor Author

Yeah I meant on md files too 🙂

@jorgeorpinel
Copy link
Contributor Author

I see it was done in #530

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p1-important Active priorities to deal within next sprints 🐛 type: bug Something isn't working. website: eng-doc DEPRECATED JS engine for /doc
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants