File tree 3 files changed +140
-57
lines changed
3 files changed +140
-57
lines changed Original file line number Diff line number Diff line change 53
53
"@solid-primitives/storage" : " ^1.3.11" ,
54
54
"@tanstack/match-sorter-utils" : " ^8.8.4" ,
55
55
"@tanstack/query-core" : " workspace:*" ,
56
- "solid-js" : " ^1.6.13 " ,
56
+ "solid-js" : " ^1.7.8 " ,
57
57
"solid-transition-group" : " ^0.2.2" ,
58
58
"superjson" : " ^1.12.4" ,
59
- "tsup-preset-solid" : " ^0.1.8 " ,
59
+ "tsup-preset-solid" : " ^2. 0.1" ,
60
60
"vite-plugin-solid" : " ^2.5.0"
61
61
}
62
62
}
Original file line number Diff line number Diff line change 1
1
// @ts -check
2
2
3
- import { defineConfig } from 'tsup-preset-solid'
3
+ import { defineConfig } from 'tsup'
4
+ import * as preset from 'tsup-preset-solid'
4
5
5
- export default defineConfig (
6
- {
7
- entry : 'src/index.tsx' ,
8
- devEntry : true ,
9
- } ,
10
- {
11
- dropConsole : true ,
12
- cjs : true ,
13
- tsupOptions : ( config ) => ( {
14
- ...config ,
15
- outDir : 'build' ,
16
- } ) ,
17
- } ,
18
- )
6
+ const preset_options = {
7
+ // array or single object
8
+ entries : [
9
+ // default entry (index)
10
+ {
11
+ // entries with '.tsx' extension will have `solid` export condition generated
12
+ entry : 'src/index.tsx' ,
13
+ // will generate a separate development entry
14
+ dev_entry : true ,
15
+ } ,
16
+ ] ,
17
+ // Set to `true` to remove all `console.*` calls and `debugger` statements in prod builds
18
+ drop_console : true ,
19
+ // Set to `true` to generate a CommonJS build alongside ESM
20
+ cjs : true ,
21
+ }
22
+
23
+ export default defineConfig ( ( ) => {
24
+ const parsed_options = preset . parsePresetOptions ( preset_options )
25
+ const tsup_options = preset . generateTsupOptions ( parsed_options )
26
+
27
+ tsup_options . forEach ( ( tsup_option ) => {
28
+ tsup_option . outDir = 'build'
29
+ } )
30
+
31
+ return tsup_options
32
+ } )
You can’t perform that action at this time.
0 commit comments