1
0
mirror of synced 2026-03-23 02:58:34 +08:00

feat(admin): 更新runtime

This commit is contained in:
roymondchen
2022-08-08 17:10:43 +08:00
committed by jia000
parent 1d8149b5eb
commit eba6cbccde
57 changed files with 42664 additions and 162 deletions

View File

@@ -33,7 +33,7 @@ export default defineConfig(({ mode }) => {
sourcemap: true,
minify: false,
target: 'esnext',
outDir: isAdmin ? `./dist/entry/react/${type}` : `../../playground/public/entry/react/${type}`,
outDir: isAdmin ? `./dist/entry/${type}` : `../../playground/public/entry/react/${type}`,
lib: {
entry: `.tmagic/${type}-entry.ts`,
@@ -47,9 +47,9 @@ export default defineConfig(({ mode }) => {
if (['page', 'playground', 'page:admin', 'playground:admin'].includes(mode)) {
const [type, isAdmin] = mode.split(':');
const base = isAdmin ? `/runtime/${type}/` : `/tmagic-editor/playground/runtime/react/${type}`;
const base = isAdmin ? `/static/react/runtime/${type}/` : `/tmagic-editor/playground/runtime/react/${type}`;
const outDir = isAdmin
? path.resolve(process.cwd(), `./dist/${type}`)
? path.resolve(process.cwd(), `./dist/runtime/${type}`)
: path.resolve(process.cwd(), `../../playground/public/runtime/react/${type}`);
return {
plugins: [