Skip to content
This repository has been archived by the owner on Feb 17, 2023. It is now read-only.

Commit

Permalink
fix: support jsx script blocks within sfc (#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
danielroe committed Mar 13, 2021
1 parent 650e7f5 commit ec3f329
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Expand Up @@ -130,7 +130,7 @@ export function createVuePlugin(rawOptions: VueViteOptions = {}): Plugin {
async transform(code, id) {
const { filename, query } = parseVueRequest(id)

if (/\.(tsx|jsx)$/.test(id)) {
if (!query.vue && /\.(tsx|jsx)$/.test(id)) {
return transformVueJsx(code, id, options.jsxOptions)
}

Expand Down

0 comments on commit ec3f329

Please sign in to comment.