Skip to content

Commit 28c5bbd

Browse files
committed
refactor(types): inherit compiler wrapper options
1 parent e169217 commit 28c5bbd

2 files changed

Lines changed: 3 additions & 9 deletions

File tree

‎src/index.ts‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { createRequire } from 'node:module';
22
import type { TransformOptions } from '@babel/core';
33
import type { LoaderDefinition } from '@rspack/core';
4-
import type { TransformOptions as NativeTransformOptions } from '@solidjs/compiler';
54
import {
65
applyRefresh,
76
getTransformFilename,
@@ -93,7 +92,7 @@ const solidLoader: LoaderDefinition<SolidLoaderOptions> = async function (
9392
...solid,
9493
filename,
9594
sourceMap: this.sourceMap || Boolean(sourceMap),
96-
} as NativeTransformOptions);
95+
});
9796

9897
callback(
9998
null,

‎src/types.ts‎

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,5 @@ export type SolidCompiler = 'babel' | 'native';
55
/** Options passed to the Solid JSX compiler. Rspack supplies the filename and source map settings. */
66
export type SolidPresetOptions = Omit<
77
TransformOptions,
8-
'filename' | 'sourceMap' | 'effectWrapper' | 'memoWrapper'
9-
> & {
10-
/** Babel also accepts a custom runtime helper name. Defaults to `'effect'`. */
11-
effectWrapper?: string | false;
12-
/** Babel also accepts a custom runtime helper name. Defaults to `'memo'`. */
13-
memoWrapper?: string | false;
14-
};
8+
'filename' | 'sourceMap'
9+
>;

0 commit comments

Comments
 (0)