Skip to content

Commit 32b9087

Browse files
authored
Merge pull request #41 from romdotdog/patch-1
fix: Update `transformInclude` to filter query strings out of paths
2 parents 1398e29 + 28bce67 commit 32b9087

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

packages/solid-styled/compiler/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export async function compile(
2727
const plugins: NonNullable<
2828
NonNullable<babel.TransformOptions['parserOpts']>['plugins']
2929
> = ['jsx'];
30-
if (/\.[mc]?tsx?$/i.test(id)) {
30+
if (/\.[mc]?tsx?$/i.test(id.split('?')[0])) {
3131
plugins.push('typescript');
3232
}
3333
const result = await babel.transformAsync(code, {

packages/unplugin/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ const solidStyledPlugin = createUnplugin(
5757
return {
5858
name: 'solid-styled',
5959
transformInclude(id): boolean {
60-
return filter(id);
60+
return filter(id.split('?')[0]);
6161
},
6262
async transform(code, id): Promise<TransformResult> {
6363
return compile(id, code, {

0 commit comments

Comments
 (0)