Skip to content

Commit 5ab322a

Browse files
committed
resolve peer conflict
1 parent 78d9807 commit 5ab322a

3 files changed

Lines changed: 251 additions & 350 deletions

File tree

packages/cli/build.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,12 @@ const newViteRolldownConfig = viteRolldownConfig.map((config) => {
124124
)`,
125125
`export const ENV_ENTRY = path.join(VITE_PACKAGE_DIR, 'dist/vite/client/env.mjs')`,
126126
);
127+
magicString.replace(
128+
`const { version } = JSON.parse(
129+
readFileSync(new URL('../../package.json', import.meta.url)).toString(),
130+
)`,
131+
`import { version } from '../../package.json' with { type: 'json' }`,
132+
);
127133
return {
128134
code: magicString,
129135
};

0 commit comments

Comments
 (0)