@@ -12,6 +12,9 @@ await Deno.writeTextFile(
12
12
( await Deno . readTextFile ( "./deno.jsonc" ) ) . replace (
13
13
"jsr:@progfay/scrapbox-parser" ,
14
14
"npm:@progfay/scrapbox-parser" ,
15
+ ) . replace (
16
+ "jsr:@cosense/types" ,
17
+ "npm:@cosense/types" ,
15
18
) ,
16
19
) ;
17
20
@@ -141,8 +144,7 @@ await build({
141
144
configFile : new URL ( "../deno_node.jsonc" , import . meta. url ) . href ,
142
145
// Don't run type checking during build to avoid Node.js compatibility issues
143
146
typeCheck : false ,
144
- declaration : "separate" ,
145
- scriptModule : false ,
147
+ declaration : "inline" ,
146
148
compilerOptions : {
147
149
lib : [ "ESNext" , "DOM" , "DOM.Iterable" ] ,
148
150
target : "ES2023" ,
@@ -153,18 +155,25 @@ await build({
153
155
154
156
// ignore snapshot testing & related test files on Node distribution
155
157
const emptyTestFiles = [
156
- "npm/esm/ browser/dom/extractCodeFiles.test.js" ,
157
- "npm/esm/ parser/anchor-fm.test.js" ,
158
- "npm/esm/ parser/spotify.test.js" ,
159
- "npm/esm/ parser/youtube.test.js" ,
160
- "npm/esm/ rest/getCodeBlocks.test.js" ,
161
- "npm/esm/ rest/pages.test.js" ,
162
- "npm/esm/ rest/project.test.js" ,
163
- "npm/esm/ websocket/_codeBlock.test.js" ,
164
- "npm/esm/ websocket/diffToChanges.test.js" ,
158
+ "browser/dom/extractCodeFiles.test.js" ,
159
+ "parser/anchor-fm.test.js" ,
160
+ "parser/spotify.test.js" ,
161
+ "parser/youtube.test.js" ,
162
+ "rest/getCodeBlocks.test.js" ,
163
+ "rest/pages.test.js" ,
164
+ "rest/project.test.js" ,
165
+ "websocket/_codeBlock.test.js" ,
166
+ "websocket/diffToChanges.test.js" ,
165
167
] ;
166
168
await Promise . all (
167
- emptyTestFiles . map ( ( filePath ) => Deno . writeTextFile ( filePath , "" ) ) ,
169
+ emptyTestFiles . map ( ( filePath ) =>
170
+ Deno . writeTextFile ( `npm/esm/${ filePath } ` , "" )
171
+ ) ,
172
+ ) ;
173
+ await Promise . all (
174
+ emptyTestFiles . map ( ( filePath ) =>
175
+ Deno . writeTextFile ( `npm/script/${ filePath } ` , "" )
176
+ ) ,
168
177
) ;
169
178
} ,
170
179
} ) ;
0 commit comments