Skip to content

Commit 62ab18b

Browse files
authored
chore: upgrade nuxt module builder to v1 (nuxt-hub#536)
1 parent 2a0f013 commit 62ab18b

File tree

30 files changed

+1155
-3043
lines changed

30 files changed

+1155
-3043
lines changed

.github/workflows/autofix.yml

-6
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,6 @@ jobs:
2020
- name: Install dependencies
2121
run: pnpm install
2222

23-
- name: prepare
24-
run: pnpm dev:prepare
25-
26-
- name: Release PR version
27-
run: pnpm dlx [email protected] publish
28-
2923
- name: Lint (code)
3024
run: pnpm lint --fix
3125

.github/workflows/ci.yml

+8-9
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@ concurrency:
2525

2626
jobs:
2727
lint:
28-
# autofix workflow will be triggered instead for PRs
29-
if: github.event_name == 'push'
3028
runs-on: ubuntu-latest
3129

3230
steps:
@@ -69,8 +67,10 @@ jobs:
6967

7068
- name: Run test suite
7169
run: pnpm test
72-
release:
73-
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
70+
71+
# - name: Run types tests
72+
# run: pnpm test:types
73+
publish:
7474
needs: [lint, test]
7575
runs-on: ubuntu-latest
7676
steps:
@@ -85,8 +85,7 @@ jobs:
8585
run: pnpm install
8686
- name: Prepare environment
8787
run: pnpm dev:prepare
88-
- name: Release Nightly
89-
run: pnpm changelogen --bump --canary --publish --publishTag nightly
90-
env:
91-
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
92-
NPM_CONFIG_PROVENANCE: true
88+
- name: Build package
89+
run: pnpm prepack
90+
- name: Publish
91+
run: pnpx pkg-pr-new publish --compact --no-template --pnpm

.nuxtrc

-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
11
imports.autoImport=false
22
typescript.includeWorkspace=true
3-
4-
# enable TypeScript bundler module resolution - https://www.typescriptlang.org/docs/handbook/modules/reference.html#bundler
5-
experimental.typescriptBundlerResolution=true

docs/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@
2626
"@rollup/plugin-yaml": "^4.1.2",
2727
"@tsparticles/engine": "^3.8.1",
2828
"@tsparticles/slim": "^3.8.1",
29-
"@vueuse/core": "^13.0.0",
30-
"@vueuse/nuxt": "^13.0.0",
29+
"@vueuse/core": "^13.1.0",
30+
"@vueuse/nuxt": "^13.1.0",
3131
"feed": "^4.2.2",
3232
"medium-zoom": "^1.1.0",
3333
"nuxt": "^3.16.2",

package.json

+17-14
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,23 @@
77
"type": "git",
88
"url": "git+https://github.com/nuxt-hub/core.git"
99
},
10+
"homepage": "https://hub.nuxt.com",
1011
"license": "Apache-2.0",
1112
"type": "module",
1213
"exports": {
1314
".": {
14-
"types": "./dist/types.d.ts",
15-
"import": "./dist/module.mjs",
16-
"require": "./dist/module.cjs"
15+
"types": "./dist/types.d.mts",
16+
"import": "./dist/module.mjs"
17+
}
18+
},
19+
"main": "./dist/module.mjs",
20+
"typesVersions": {
21+
"*": {
22+
".": [
23+
"./dist/types.d.mts"
24+
]
1725
}
1826
},
19-
"main": "./dist/module.cjs",
20-
"types": "./dist/types.d.ts",
21-
"homepage": "https://hub.nuxt.com",
2227
"files": [
2328
"dist"
2429
],
@@ -32,7 +37,7 @@
3237
],
3338
"scripts": {
3439
"prepack": "nuxt-module-build build",
35-
"dev:prepare": "nuxt-module-build build --stub; nuxt-module-build prepare; nuxi prepare playground",
40+
"dev:prepare": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxi prepare playground",
3641
"dev": "nuxi dev playground",
3742
"dev:build": "nuxi build playground",
3843
"docs": "PORT=4000 nuxi dev docs",
@@ -41,7 +46,8 @@
4146
"lint": "eslint .",
4247
"lint:fix": "eslint . --fix",
4348
"test": "vitest run --test-timeout=60000",
44-
"test:watch": "vitest watch"
49+
"test:watch": "vitest watch",
50+
"test:types": "vue-tsc --noEmit && cd playground && vue-tsc --noEmit"
4551
},
4652
"dependencies": {
4753
"@cloudflare/workers-types": "^4.20250407.0",
@@ -67,22 +73,19 @@
6773
"devDependencies": {
6874
"@nuxt/devtools": "^2.3.2",
6975
"@nuxt/eslint-config": "^1.3.0",
70-
"@nuxt/module-builder": "^0.8.4",
76+
"@nuxt/module-builder": "^1.0.0",
7177
"@nuxt/schema": "^3.16.2",
7278
"@nuxt/test-utils": "^3.17.2",
7379
"@nuxthub/core": "link:",
7480
"@types/node": "^22.14.0",
7581
"changelogen": "^0.6.1",
7682
"eslint": "^9.24.0",
7783
"nuxt": "^3.16.2",
78-
"typescript": "5.6.3",
84+
"typescript": "~5.8.3",
7985
"vitest": "^3.1.1",
86+
"vue-tsc": "^2.2.8",
8087
"wrangler": "^4.9.0"
8188
},
82-
"resolutions": {
83-
"h3": "^1.14.0",
84-
"@nuxtjs/mdc": "https://pkg.pr.new/@nuxtjs/mdc@cd1c4fd"
85-
},
8689
"packageManager": "[email protected]",
8790
"pnpm": {
8891
"onlyBuiltDependencies": [

playground/app/pages/browser.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ const capture = async () => {
4242
</div>
4343
</template>
4444
<UAlert v-if="!image" :title="loading ? 'Capturing...' : 'No screenshot captured'" color="neutral" variant="outline" icon="i-lucide-info" />
45-
<img v-if="image" :src="image" class="rounded border dark:border-gray-800" style="aspect-ratio: 16/9;" :class="{ 'animate-pulse': loading }">
45+
<img v-if="image" :src="image" class="rounded border border-(--ui-border)" style="aspect-ratio: 16/9;" :class="{ 'animate-pulse': loading }">
4646
<UAlert v-if="framework" class="mt-4" :class="{ 'animate-pulse': loading }" :title="`This website is made with ${framework}`" color="neutral" variant="outline" icon="i-lucide-code-xml" />
4747
<div class="mt-4">
4848
Or open our <UButtonGroup>

playground/package.json

+11-11
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,24 @@
99
"preview": "nuxi preview"
1010
},
1111
"dependencies": {
12-
"@ai-sdk/vue": "^1.2.2",
13-
"@cloudflare/puppeteer": "^0.0.15",
14-
"@iconify-json/simple-icons": "^1.2.29",
12+
"@ai-sdk/vue": "^1.2.7",
13+
"@cloudflare/puppeteer": "^1.0.1",
14+
"@iconify-json/simple-icons": "^1.2.31",
1515
"@kgierke/nuxt-basic-auth": "^1.7.0",
1616
"@nuxt/ui": "3.0.2",
1717
"@nuxthub/core": "latest",
1818
"@nuxtjs/mdc": "^0.16.1",
19-
"@vueuse/core": "^13.0.0",
20-
"@vueuse/nuxt": "^13.0.0",
21-
"ai": "^4.2.8",
19+
"@vueuse/core": "^13.1.0",
20+
"@vueuse/nuxt": "^13.1.0",
21+
"ai": "^4.3.4",
2222
"aws4fetch": "^1.0.20",
2323
"drizzle-orm": "^0.41.0",
24-
"nuxt": "^3.16.1",
25-
"nuxt-auth-utils": "^0.5.17",
24+
"nuxt": "^3.16.2",
25+
"nuxt-auth-utils": "^0.5.19",
2626
"postgres": "^3.4.5",
27-
"puppeteer": "^24.4.0",
28-
"tailwindcss": "^4.0.17",
29-
"workers-ai-provider": "^0.2.1",
27+
"puppeteer": "^24.6.0",
28+
"tailwindcss": "^4.1.3",
29+
"workers-ai-provider": "^0.3.0",
3030
"zod": "^3.24.2"
3131
},
3232
"devDependencies": {

0 commit comments

Comments
 (0)