feat: Ensure docs example code is syntactically valid
anishkny opened this issue · 2 comments
anishkny commented
To prevent issues like #2606 (comment)
equinusocio commented
... and #2601
Deleted user commented
Thanks for raising this :) To address it:
- Reviews of docs will hopefully be more thorough now that 3.0 craziness is over ;)
- I'm gradually moving larger samples to live StackBlitz demos like we have in the Quick Tour, which (in my experience anyway) helps with accuracy of code samples.
- StackBlitz samples are not inline, they're stored in separate files (e.g. https://github.com/Polymer/docs/tree/master/app/3.0/samples) that get uploaded to StackBlitz when the user clicks on a sample. It's a little more work to set them up than just dropping some code inline in a document. I would probably not do a StackBlitz example for stuff that's just a 3-liner thing. So if this is a feature request for implementing linting/parsing of inline samples, I don't think we have the bandwidth to do that now.
@arthurevans or @keanulee might have a different take or more info. Tagging them in case that is true.