caoxiemeihao / vite-plugins

🌱 为社区尽一份绵薄之力
MIT License
65 stars 15 forks source link

[Question] If I write number comparison like `a<b` ? Will this `.vue` file be marked as JSX ? #3

Closed chenxxzhe closed 3 years ago

caoxiemeihao commented 3 years ago

Yes. This judgment is not rigorous enough, I plan to fix it in the next version.

caoxiemeihao commented 3 years ago

更可靠的方式需要使用 语法分析了,不过会消耗一些性能 其次 a<b 这种代码被加上了 lang="jsx",按理说也不会影响使用

caoxiemeihao commented 2 years ago

新版本已经用 ast 语法解析了 https://www.npmjs.com/package/vite-plugin-lang-jsx/v/1.2.0