diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index cba84769ec..5e592168be 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -42,6 +42,8 @@ jobs: - name: Build application run: pnpm run docs:build + env: + NODE_OPTIONS: '--max-old-space-size=8192' - name: Deploy to NuxtHub uses: nuxt-hub/action@v1 diff --git a/.github/workflows/module.yml b/.github/workflows/module.yml index 1d5027e160..1405494619 100644 --- a/.github/workflows/module.yml +++ b/.github/workflows/module.yml @@ -18,7 +18,7 @@ jobs: strategy: matrix: - os: [ubuntu-latest] # macos-latest, windows-latest + os: [ubuntu-latest, windows-latest] # macos-latest node: [22] env: @@ -65,6 +65,7 @@ jobs: run: pnpm run dev:vue:build - name: Publish + if: matrix.os != 'windows-latest' run: pnpx pkg-pr-new publish --compact --no-template --pnpm starter-nuxt: diff --git a/.npmrc b/.npmrc index 1c85172969..a6c380f6b3 100644 --- a/.npmrc +++ b/.npmrc @@ -1,4 +1,3 @@ shamefully-hoist=true auto-install-peers=true ignore-workspace-root-check=true -shell-emulator=true diff --git a/build.config.ts b/build.config.ts index 508575c023..c3d7c4cc09 100644 --- a/build.config.ts +++ b/build.config.ts @@ -6,8 +6,13 @@ export default defineBuildConfig({ './src/unplugin', './src/vite' ], - replace: { - 'process.env.DEV': 'false' + rollup: { + replace: { + delimiters: ['', ''], + values: { + 'process.argv.at(-1) === \'--uiDev\'': 'false' + } + } }, hooks: { 'mkdist:entry:options'(ctx, entry, options) { diff --git a/package.json b/package.json index 8a348dcc9a..5b3611d5f2 100644 --- a/package.json +++ b/package.json @@ -89,13 +89,13 @@ "scripts": { "build": "nuxt-module-build build", "prepack": "pnpm build", - "dev": "DEV=true nuxi dev playground", + "dev": "nuxi dev playground --uiDev", "dev:build": "nuxi build playground", - "dev:vue": "DEV=true vite playground-vue", + "dev:vue": "vite playground-vue -- --uiDev", "dev:vue:build": "vite build playground-vue", "dev:prepare": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxi prepare playground && nuxi prepare docs && vite build playground-vue", - "docs": "DEV=true nuxi dev docs", - "docs:build": "NODE_OPTIONS='--max-old-space-size=8192' nuxi build docs", + "docs": "nuxi dev docs --uiDev", + "docs:build": "nuxi build docs", "docs:prepare": "nuxt-component-meta docs", "lint": "eslint .", "lint:fix": "eslint . --fix", diff --git a/src/templates.ts b/src/templates.ts index 3fa2e6ec0c..e4578cfbf8 100644 --- a/src/templates.ts +++ b/src/templates.ts @@ -50,7 +50,7 @@ export function getTemplates(options: ModuleOptions, uiConfig: Record