Skip to content

Commit

Permalink
chore: build seems to be working again
Browse files Browse the repository at this point in the history
  • Loading branch information
stipsan committed Jul 9, 2024
1 parent 253e4af commit 843aa4d
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
12 changes: 11 additions & 1 deletion packages/@repo/package.bundle/src/package.bundle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {version} from '../package.json'
export const defaultConfig: UserConfig = {
appType: 'custom',
define: {
'__DEV__': 'false',
'process.env.PKG_VERSION': JSON.stringify(version),
'process.env.NODE_ENV': '"production"',
'process.env': {},
Expand All @@ -19,7 +20,13 @@ export const defaultConfig: UserConfig = {
formats: ['es'],
},
rollupOptions: {
external: ['react', /^react-dom/, 'react/jsx-runtime', 'styled-components'],
external: [
'react',
/^react-dom/,
'react/jsx-runtime',
'styled-components',
'./checkoutPairWorker.ts',
],
output: {
exports: 'named',
dir: 'dist',
Expand All @@ -30,4 +37,7 @@ export const defaultConfig: UserConfig = {
},
},
},
worker: {
format: 'es',
},
}
4 changes: 3 additions & 1 deletion packages/sanity/package.worker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ export default defineConfig(() => {
lib: {
entry: './src/core/store/_legacy/document/document-pair/checkoutPairWorker.ts',
fileName: 'checkoutPair',
name: 'checkoutPair',
},
rollupOptions: {
external: [],
Expand All @@ -20,5 +19,8 @@ export default defineConfig(() => {
},
},
},
worker: {
format: 'iife',
},
})
})

0 comments on commit 843aa4d

Please sign in to comment.