This website requires JavaScript.
Explore
Help
Sign In
vitalif-js
/
prettier
Watch
1
Star
0
Fork
You've already forked prettier
0
Code
Issues
Pull Requests
Projects
Releases
Wiki
Activity
e742a1c80b
prettier
/
tests
/
multiparser_vue
/
jsfmt.spec.js
2 lines
30 B
JavaScript
Raw
Normal View
History
Unescape
Escape
[vue] Introduce proper support for Vue Single File Components (SFC) (#3563) There's a lot of demand for vue sfc (#2097). This introduces partial support for them: all the html is printed as is, except for the script and style tags which are printed using prettier. I believe that this should cover a lot of the use cases while being simple to support and if we want we can extend to more in the future. I copy pasted the html parser used by vue (it's just a single 400 lines file) so that we don't run the chancesof conflicts. I'm also very conservative: I only print the style and script at the top level and for the lang attributes we support. I expect this to be landable as is and provide value, review welcome :)
2017-12-25 03:15:33 +03:00
run
_spec
(
_
_dirname
,
[
"vue"
]
)
;