Skip to content

Migrate to Nuxt4 folder format#5

Merged
ejfine merged 6 commits intomainfrom
nuxt4
Nov 29, 2025
Merged

Migrate to Nuxt4 folder format#5
ejfine merged 6 commits intomainfrom
nuxt4

Conversation

@ejfine
Copy link
Contributor

@ejfine ejfine commented Nov 29, 2025

Why is this change necessary?

Nuxt 4 is good

How does this change address the issue?

rearranges folder structure, adds different packages to package.json

What side effects does this change have?

Things must use Nuxt 4

How is this change tested?

Downstream repo

Summary by CodeRabbit

  • New Features

    • Expanded UI theme options with a broader color palette and refined input/menu sizing
    • Optional GraphQL Apollo client support and new icon library integration
  • Chores

    • Reorganized application and Nuxt configuration templates
    • Updated package manifest and dev tooling (testing, codegen, and build tools)
    • ESLint updated to support vitest
    • Adjusted TypeScript config for type resolution
    • Removed a CI-related template variable and its test fixtures

✏️ Tip: You can customize this high-level summary in your review settings.

@ejfine ejfine self-assigned this Nov 29, 2025
@coderabbitai
Copy link

coderabbitai bot commented Nov 29, 2025

Walkthrough

Moves app config into app/, removes a root nuxt.config.ts in favor of a templated nuxt.config.ts.jinja, adds TypeScript and Nuxt type declarations, updates package manifest template and ESLint for vitest, and removes a copier CI variable plus its test-data entries.

Changes

Cohort / File(s) Summary
App config moved/changed
template/{{ app_name }}_app/app.config.ts, template/{{ app_name }}_app/app/app.config.ts
Removed the root file's default export of defineAppConfig(...) (previous ui.primary/ui.gray and tooltip.openDelay). Added app/app.config.ts exporting defineAppConfig with expanded ui.colors and ui.inputMenu.slots.content.
Nuxt config template
template/{{ app_name }}_app/nuxt.config.ts, template/{{ app_name }}_app/nuxt.config.ts.jinja
Deleted the static nuxt.config.ts. Added nuxt.config.ts.jinja with a templated Nuxt config (compatibility, devtools, modules, global CSS, Nitro prerender, Vite polling) and conditional blocks for backend proxy and Apollo GraphQL.
Package manifest template
template/{{ app_name }}_app/package.json.jinja
Added packageManager field; expanded and reworked dependencies/devDependencies (icon/font packages, Nuxt tooling, GraphQL codegen tooling gated by frontend_uses_graphql, testing/build tooling, version placeholders, conditional backend tooling).
ESLint / testing
template/{{ app_name }}_app/eslint.config.mjs
Added eslint-plugin-vitest and a test-files config block (*.test.ts, *.spec.ts) enabling vitest plugin, merging vitest rules, and applying several rule overrides.
TypeScript config & types
template/{{ app_name }}_app/tsconfig.json, template/{{ app_name }}_app/types/nuxt.config.d.ts
Removed strict: true and top-level include/exclude from tsconfig.json; added typeRoots. Added types/nuxt.config.d.ts augmenting nuxt/schema to include optional apollo.clients.default.httpEndpoint: string.
Global declarations removed
template/{{ app_name }}_app/global.d.ts
Deleted the global augmentation that declared defineAppConfig and removed the file's export {}; placeholder.
Copier template and tests
copier.yml, tests/copier_data/data1.yaml, tests/copier_data/data2.yaml
Removed use_windows_in_ci variable from copier.yml and removed use_windows_in_ci entries from both test data YAML files.
CI matrix update
.copier-answers.yml, .github/workflows/ci.yaml
Added Python 3.13.2 to .copier-answers.yml python_ci_versions and to the CI workflow matrix in .github/workflows/ci.yaml.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20–30 minutes

  • Check package.json.jinja conditional logic and version placeholders.
  • Verify Jinja conditionals and proxy/Apollo blocks in nuxt.config.ts.jinja.
  • Inspect eslint.config.mjs vitest plugin setup and rule overrides.
  • Confirm types/nuxt.config.d.ts augmentation aligns with Nuxt schema usage.
  • Validate impact of moving/removing app config and deleting global.d.ts on consumers/imports.
  • Ensure removal of use_windows_in_ci doesn't break template tests or CI expectations.

Pre-merge checks

✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title 'Migrate to Nuxt4 folder format' accurately reflects the primary change: restructuring the project's folder layout for Nuxt 4 compatibility.
Description check ✅ Passed The description covers most required template sections (Why, How, Side effects, Testing) with relevant information about the Nuxt 4 migration, though explanations are minimal and lack specific technical details.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

📜 Recent review details

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1dc313e and c5c41b4.

📒 Files selected for processing (2)
  • .copier-answers.yml (1 hunks)
  • .github/workflows/ci.yaml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: lint-matrix (ubuntu-24.04, 3.13.2, --data-file tests/copier_data/data1.yaml)
  • GitHub Check: lint-matrix (ubuntu-24.04, 3.12.7, --data-file tests/copier_data/data1.yaml)
  • GitHub Check: lint-matrix (ubuntu-24.04, 3.13.2, --data-file tests/copier_data/data2.yaml)
  • GitHub Check: lint-matrix (ubuntu-24.04, 3.12.7, --data-file tests/copier_data/data2.yaml)
🔇 Additional comments (2)
.copier-answers.yml (1)

7-9: Verify Python 3.13.2 compatibility and alignment with PR objectives.

The addition of Python 3.13.2 to the CI matrix is consistent with the concurrent update to .github/workflows/ci.yaml. However, this PR is scoped as a Nuxt4 migration, and Python version matrix updates appear orthogonal to that goal. Ensure that:

  1. Python 3.13.2 has been thoroughly tested with the Nuxt4 setup and all project dependencies.
  2. This change is intentional and necessary for the Nuxt4 migration (or should be in a separate maintenance PR).
.github/workflows/ci.yaml (1)

41-42: Verify Python 3.13.2 stability in test matrix.

The addition of Python 3.13.2 to the lint-matrix is consistent with .copier-answers.yml and expands test coverage. However, ensure that:

  1. Python 3.13.2 is stable and compatible with the project's dependencies (Node.js 24.7.0, Nuxt 4, and all test tooling).
  2. Tests pass reliably on this version before merging.

Also note: The AI summary mentions "removes a copier CI variable plus its test-data entries," but those removals are not visible in the provided files. Verify that test data files (tests/copier_data/data1.yaml and tests/copier_data/data2.yaml) reflect any intended changes.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
template/{{ app_name }}_app/eslint.config.mjs (1)

1-48: Vitest ESLint setup is well-scoped; double‑check use of configs.all vs configs.recommended

Scoping the Vitest plugin to **/*.{test,spec}.ts and layering your own overrides makes sense. One thing to verify is whether you really want ...vitest.configs.all.rules (which can be quite strict/noisy and may change over time) versus the more typical configs.recommended:

-    rules: {
-      ...vitest.configs.all.rules,
+    rules: {
+      ...vitest.configs.recommended.rules,
       "vitest/no-focused-tests": ["error", { fixable: false }],
       "vitest/consistent-test-filename": ["error", { pattern: ".*\\.spec\\.ts$" }],
       // other customizations...

That tends to be easier to live with for templates while still catching most issues.

Please confirm in the eslint-plugin-vitest docs for the version you’re pinning that configs.all / configs.recommended exist with the expected shape (.rules) so this spread doesn’t break ESLint config resolution.

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5f0ad7b and 0b0a447.

📒 Files selected for processing (9)
  • template/{{ app_name }}_app/app.config.ts (0 hunks)
  • template/{{ app_name }}_app/app/app.config.ts (1 hunks)
  • template/{{ app_name }}_app/eslint.config.mjs (3 hunks)
  • template/{{ app_name }}_app/global.d.ts (0 hunks)
  • template/{{ app_name }}_app/nuxt.config.ts (0 hunks)
  • template/{{ app_name }}_app/nuxt.config.ts.jinja (1 hunks)
  • template/{{ app_name }}_app/package.json.jinja (1 hunks)
  • template/{{ app_name }}_app/tsconfig.json (1 hunks)
  • template/{{ app_name }}_app/types/nuxt.config.d.ts (1 hunks)
💤 Files with no reviewable changes (3)
  • template/{{ app_name }}_app/app.config.ts
  • template/{{ app_name }}_app/nuxt.config.ts
  • template/{{ app_name }}_app/global.d.ts
🔇 Additional comments (3)
template/{{ app_name }}_app/tsconfig.json (1)

4-6: typeRoots addition looks correct; verify types/ is present in generated apps

Extending .nuxt/tsconfig.json and adding "typeRoots": ["types", "node_modules/@types"] is a good way to ensure your local ambient declarations (e.g. in types/) are picked up without losing @types/*. Just make sure the template always generates a types/ directory (with things like nuxt.config.d.ts) so editors and vue-tsc resolve them as expected in downstream projects.

Please run a vue-tsc --noEmit / pnpm type-check in at least one generated app to confirm that the types/ folder is being picked up and no type roots went missing.

template/{{ app_name }}_app/app/app.config.ts (1)

1-18: Nuxt UI defineAppConfig usage looks good; confirm placement under app/ for Nuxt 4

The shape of ui.colors and ui.inputMenu.slots.content is consistent with Nuxt UI’s app config expectations, and using defineAppConfig is appropriate here. The only thing to double‑check is that, for Nuxt 4’s folder layout, app/app.config.ts is indeed the recommended location (vs. root‑level app.config.ts) in the version you’re targeting, so that both runtime and type inference pick it up correctly.

Please confirm against the Nuxt 4 docs (or by running nuxt dev in a generated app) that app/app.config.ts is discovered as expected and that the UI config appears in the devtools/app config inspector.

template/{{ app_name }}_app/types/nuxt.config.d.ts (1)

1-13: Waiting for web search results to validate the Apollo schema structure...

Comment on lines +4 to +53
compatibilityDate: "2024-11-01",
future: {
compatibilityVersion: 4,
},
devtools: { enabled: process.env.NODE_ENV !== "test" },
telemetry: process.env.NODE_ENV !== "test",
// the conditional modules added in by the template make it complicated to format consistently...at least with only 3 'always included' modules
// prettier-ignore
modules: [
"@nuxt/ui",
["@nuxt/eslint", { devOnly: true }],
["@nuxt/test-utils/module", { devOnly: true }],
],
css: ["~/assets/css/main.css"],
experimental: { appManifest: false }, // https://github.com/nuxt/nuxt/issues/30461#issuecomment-2572616714
nitro: {
prerender: {
concurrency: 1, // lower the concurrency to not be such a memory hog
interval: 200, // ms pause between batches – lets the Garbage Collector catch up
},{% endraw %}{% if has_backend %}{% raw %}
devProxy: {
// this is just a proxy used for `pnpm dev`
"/api": {
target: "http://localhost:4000", // backend dev port
changeOrigin: true, // rewrite Host header
prependPath: false, // keep /api prefix
},
},{% endraw %}{% endif %}{% raw %}
},
vite: {
server: {
watch: {
usePolling: true, // this seems to be explicitly needed when in a devcontainer in order for hot reloading to work
},{% endraw %}{% if has_backend %}{% raw %}
proxy: {
// this is just a proxy used for `pnpm dev`
"/api": {
target: "http://localhost:4000", // backend dev port
changeOrigin: true,
},
},{% endraw %}{% endif %}{% raw %}
},
},{% endraw %}{% if frontend_uses_graphql %}{% raw %}
apollo: {
clients: {
default: {
httpEndpoint: "/api/graphql",
},
},
},{% endraw %}{% endif %}{% raw %}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick | 🔵 Trivial

Nuxt config template is coherent; consider aligning modules with installed Nuxt modules

The core config (compatibility, devtools/telemetry, Nitro prerender, dev proxy, Vite proxy, and conditional apollo block) looks consistent and should work for both backend and GraphQL variants.

Given package.json.jinja installs @nuxt/fonts, @nuxt/icon, @nuxtjs/color-mode and (optionally) @nuxtjs/apollo, it may be worth explicitly registering those here, e.g.:

  • Always‑on modules: @nuxt/fonts, @nuxt/icon, @nuxtjs/color-mode
  • Conditional module when frontend_uses_graphql: @nuxtjs/apollo

so that every installed Nuxt module is actually activated via modules: [...] in generated apps.

Please verify, against the versions you’re using, whether @nuxt/ui already pulls in the fonts/icon modules for you or if they still need explicit entries here, and whether @nuxtjs/apollo requires a modules registration in Nuxt 4 (docs/examples for that version are the best source of truth).

🤖 Prompt for AI Agents
In template/{{ app_name }}_app/nuxt.config.ts.jinja around lines 4-53, the
modules array doesn't include the Nuxt packages installed in package.json.jinja;
update the modules list to explicitly include "@nuxt/fonts", "@nuxt/icon", and
"@nuxtjs/color-mode" alongside the existing entries, and add "@nuxtjs/apollo"
conditionally when frontend_uses_graphql is true, keeping the existing devOnly
wrappers for eslint/test-utils; ensure the array formatting and any template
conditionals remain consistent and verify via Nuxt 4 docs whether @nuxt/ui
already supplies fonts/icons and whether @nuxtjs/apollo still requires explicit
registration so the generated app activation matches package.json.

Comment on lines +5 to 21
"packageManager": "pnpm@{% endraw %}{{ pnpm_version }}{% raw %}",
"scripts": {
"type-check": "vue-tsc --noEmit",
"lint": "eslint . --fix --ext .vue,.ts,.js",
"build": "pnpm run type-check && nuxt build",
"build": "nuxt build",
"comment-about-dev-no-fork": "sometimes it seems needed, other times it seems to work with it...more info https://github.com/nuxt/cli/issues/181",
"dev": "nuxt dev --no-fork",
"dev": "nuxt dev --no-fork",{% endraw %}{% if has_backend %}{% raw %}
"openapi-codegen": "mkdir -p ./app/generated/open-api/backend && docker run --network host --user $(id -u):$(id -g) -v ./app/generated/open-api/backend:/app/output -v $PWD/../backend/tests/unit/__snapshots__/test_basic_server_functionality/test_openapi_schema.json:/app/openapi.json mcr.microsoft.com/openapi/kiota:{% endraw %}{{ kiota_cli_version }}{% raw %} generate -l typescript -c BackendClient -n client -d openapi.json --exclude-backward-compatible --clean-output --additional-data false && python3 ./kiota_nullable_fixer.py",{% endraw %}{% endif %}{% raw %}
"generate": "nuxt generate",
"preview": "nuxt preview",
"postinstall": "nuxt prepare && pnpm exec playwright-core install --only-shell chromium-headless-shell",
"test-unit": "vitest --dir tests/unit run --coverage",
"test-unit:watch": "vitest --dir tests/unit",
"test-e2e": "vitest --dir tests/e2e run",
"test-e2e:docker": "docker compose --file=../docker-compose.yaml build && USE_DOCKER_COMPOSE_FOR_VITEST_E2E=1 vitest --dir tests/e2e run",
"test-e2e:watch": "vitest --dir tests/e2e"
"test-unit": "vitest --exclude=\"tests/e2e/**\" --exclude=\"tests/compiled/**\" --run --coverage",
"test-unit:watch": "vitest --exclude=\"tests/e2e/**\" --exclude=\"tests/compiled/**\"",
"test-compiled": "vitest --exclude=\"tests/e2e/**\" --exclude=\"tests/unit/**\" --test-timeout=15000 --run",
"test-e2e": "docker compose --file=../docker-compose.yaml build && dotenv -v USE_DOCKER_COMPOSE_FOR_VITEST_E2E=1 -- vitest --exclude=\"tests/unit/**\" --exclude=\"tests/compiled/**\" --test-timeout=15000 --run",
"test-compiled:watch": "vitest --exclude=\"tests/e2e/**\" --exclude=\"tests/unit/**\" --test-timeout=15000"
},
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

# First, let's understand the repo structure and check for README/docs
git ls-files | head -30

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 1132


🏁 Script executed:

# Check if there's a README in the template directory or repo root
fd -t f 'README|SETUP|PLATFORM|REQUIREMENTS' -i

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 126


🏁 Script executed:

# Look for the backend path mentioned in the review
find . -type f -path "*backend/tests/unit/__snapshots__/test_basic_server_functionality*" 2>/dev/null

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 74


🏁 Script executed:

# Check the actual template structure to understand context
fd -type f -name "*.jinja" | grep -E "(package|docker|compose)" | head -20

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 262


🏁 Script executed:

# Look for any CI/CD configuration that hints at platform support
fd -type f \( -name "*.yml" -o -name "*.yaml" -o -name ".github" \) | head -20

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 262


🏁 Script executed:

# Read the specific package.json.jinja file to see full context
wc -l template/*/package.json.jinja 2>/dev/null || echo "Looking for package.json.jinja files..."
fd -type f -name "package.json.jinja"

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 329


🏁 Script executed:

# Read the template README to see platform requirements
cat template/README.md.jinja

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 2669


🏁 Script executed:

# Read the full package.json.jinja file
cat template/{{ app_name }}_app/package.json.jinja

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 234


🏁 Script executed:

# Check CI configuration to see what platforms are targeted
cat .github/workflows/ci.yaml

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 6613


🏁 Script executed:

# Find and read package.json.jinja safely
fd -type f -name "package.json.jinja" -exec cat {} \;

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 262


🏁 Script executed:

# Check copier configuration for any platform/OS hints
cat copier.yml 2>/dev/null || cat _copier.yml 2>/dev/null || cat _copier_answers.yml 2>/dev/null || echo "Checking for copier config..."
fd -type f -name "copier*.yml" -o -name "_copier*.yml" | head -5

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 4688


🏁 Script executed:

# Check if there's any .devcontainer that hints at Windows support
cat .devcontainer/devcontainer.json | head -50

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 2072


🏁 Script executed:

# Look for any Windows-specific handling
rg -i "windows|msys|cygwin|powershell" --type yaml --type json --type sh -C 2

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 1457


🏁 Script executed:

# Find and read package.json.jinja file
find . -name "package.json.jinja" -type f -exec cat {} \;

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 5171


🏁 Script executed:

# Check if there are conditional scripts based on Windows or platform
rg -A 5 "openapi-codegen|test-e2e" --type jinja

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 2105


🏁 Script executed:

# Look for Windows-specific handling in the Nuxt app templates
fd -type f -name "*.jinja" | xargs grep -l "windows\|Windows\|WINDOWS" 2>/dev/null | head -10

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 262


🏁 Script executed:

# Check if CI workflow generation is conditional on use_windows_in_ci
find . -name "*.yaml.jinja" -o -name "*.yml.jinja" | xargs grep -l "use_windows_in_ci\|windows" 2>/dev/null | head -10

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 74


🏁 Script executed:

# Look for CI workflow template in the generated app
find . -path "*/template/*" -name "*.yaml.jinja" -o -name "*.yml.jinja" | head -20

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 261


🏁 Script executed:

# Check if CI workflow includes Windows conditionally
cat ./template/.github/workflows/ci.yaml.jinja | head -100

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 3029


🏁 Script executed:

# Check for any Windows-specific script handling in the template
rg "use_windows_in_ci" -A 5 -B 5 ./template/

Repository: LabAutomationAndScreening/copier-nuxt-static-aws

Length of output: 74


Based on my verification, I have found that:

  1. The openapi-codegen script is indeed Unix-only: It uses $(id -u):$(id -g), $PWD, mkdir -p, and python3 — all Unix/bash conventions that fail on Windows cmd/PowerShell.

  2. The test-e2e script depends on Docker and bash syntax (e.g., dotenv -v with bash environment variables).

  3. Critical finding: The copier.yml defines a use_windows_in_ci option (defaulting to no), but:

    • It's not actually used in the CI workflow template (.github/workflows/ci.yaml.jinja)
    • No Windows test matrix is generated regardless of this flag
    • This makes the option a dead code artifact
  4. The template is effectively Linux-only via devcontainer-first design, but offers a misleading Windows option with no actual implementation.

The original review's concerns are substantiated and important. The issue is broader than just documentation—there's an inconsistency between the template's configurability and actual implementation.


Scripts assume Linux/Unix environment; Windows CI flag is non-functional

The openapi-codegen script is Linux-only (uses $(id -u):$(id -g), $PWD, mkdir -p, and python3). The test-e2e script depends on Docker and bash-specific syntax. Both require a Unix-like shell that Windows cmd/PowerShell doesn't provide natively.

However, a more significant issue: copier.yml defines a use_windows_in_ci option, but it's never used in the CI workflow template and generates no effect. This creates a false expectation of Windows support.

Recommendations:

  • Either remove the use_windows_in_ci flag from copier.yml and document that this template targets Linux/devcontainers, or
  • Implement Windows support by conditionalizing the frontend scripts (e.g., providing Windows batch/PowerShell equivalents or documenting that Windows users must skip openapi-codegen and Docker-based e2e tests)
  • Update template README to explicitly state: "Linux/devcontainer-first; Windows option in copier.yml is not yet implemented."
🤖 Prompt for AI Agents
In template/{{ app_name }}_app/package.json.jinja around lines 5-21 the scripts
(notably "openapi-codegen" and "test-e2e") use Unix-only shell features and
assume Docker/bash/python3, while copier.yml exposes a use_windows_in_ci option
that is never wired into the CI template, creating a misleading Windows option;
fix this by either (A) removing the unused use_windows_in_ci option from
copier.yml and updating README to state the template is Linux/devcontainer-first
and document Windows limitations, and also annotate these scripts in
package.json.jinja as Unix-only, or (B) implement proper Windows support by
adding conditional/script variants (PowerShell/cmd-compatible commands or
cross-platform Node scripts) and updating .github/workflows/ci.yaml.jinja to
include a Windows matrix when use_windows_in_ci is enabled; pick one approach
and apply consistent updates to copier.yml, CI workflow template, README, and
package.json.jinja to avoid the dead flag and mismatched expectations.

Comment on lines 22 to 68
"dependencies": {
"@iconify-json/lucide": "{% endraw %}{{ iconify_json_lucide_version }}{% raw %}",
"@iconify/vue": "{% endraw %}{{ iconify_vue_version }}{% raw %}",
"@nuxt/fonts": "{% endraw %}{{ nuxt_fonts_version }}{% raw %}",
"@nuxt/icon": "{% endraw %}{{ nuxt_icon_version }}{% raw %}",
"@nuxt/ui": "{% endraw %}{{ nuxt_ui_version }}{% raw %}",
"@nuxtjs/color-mode": "{% endraw %}{{ nuxtjs_color_mode_version }}{% raw %}",
"nuxt": "{% endraw %}{{ nuxt_version }}{% raw %}",
"typescript": "{% endraw %}{{ typescript_version }}{% raw %}",
"vue": "^3.5.13",
"vue-router": "^4.5.0"
"vue": "{% endraw %}{{ vue_version }}{% raw %}",
"vue-router": "{% endraw %}{{ vue_router_version }}{% raw %}"
},
"devDependencies": {
"@nuxt/eslint": "^1.2.0",
"@nuxt/schema": "^3.0.0",
"@nuxt/test-utils": "^3.17.2",
"@faker-js/faker": "{% endraw %}{{ faker_version }}{% raw %}",{% endraw %}{% if frontend_uses_graphql %}{% raw %}
"@graphql-codegen/cli": "{% endraw %}{{ graphql_codegen_cli_version }}{% raw %}",
"@graphql-codegen/typescript": "{% endraw %}{{ graphql_codegen_typescript_version }}{% raw %}",
"@graphql-codegen/typescript-operations": "{% endraw %}{{ graphql_codegen_typescript_operations_version }}{% raw %}",
"@graphql-codegen/typescript-vue-apollo": "^4.1.2",
"@graphql-tools/mock": "^9.0.22",
"@graphql-tools/schema": "^10.0.23",{% endraw %}{% endif %}{% raw %}
"@nuxt/eslint": "{% endraw %}{{ nuxt_eslint_version }}{% raw %}",
"@nuxt/schema": "{% endraw %}{{ nuxt_version }}{% raw %}",
"@nuxt/test-utils": "{% endraw %}{{ nuxt_test_utils_version }}{% raw %}",{% endraw %}{% if frontend_uses_graphql %}{% raw %}
"@nuxtjs/apollo": "{% endraw %}{{ nuxt_apollo_version }}{% raw %}",{% endraw %}{% endif %}{% raw %}
"@nuxtjs/eslint-config-typescript": "^12.1.0",
"@vitest/coverage-v8": "^3.0.9",
"@vue/devtools-api": "^7.7.2",
"@vue/test-utils": "^2.4.6",
"@playwright/test": "{% endraw %}{{ playwright_version }}{% raw %}",
"@types/node": "{% endraw %}{{ types_node_version }}{% raw %}",
"@vitest/coverage-istanbul": "{% endraw %}{{ vitest_version }}{% raw %}",{% endraw %}{% if frontend_uses_graphql %}{% raw %}
"@vue/apollo-composable": "^4.2.2",{% endraw %}{% endif %}{% raw %}
"@vue/devtools-api": "{% endraw %}{{ vue_devtools_api_version }}{% raw %}",
"@vue/test-utils": "{% endraw %}{{ vue_test_utils_version }}{% raw %}",
"autoprefixer": "^10.4.21",
"eslint": "^9.22.0",
"flush-promises": "^1.0.2",
"happy-dom": "^17.4.4",
"playwright-core": "^1.51.1",
"dotenv-cli": "{% endraw %}{{ dotenv_cli_version }}{% raw %}",
"eslint": "{% endraw %}{{ eslint_version }}{% raw %}",
"eslint-plugin-vitest": "^0.5.4",{% endraw %}{% if frontend_uses_graphql %}{% raw %}
"graphql": "^16.12.0",
"graphql-tag": "^2.12.6",{% endraw %}{% endif %}{% raw %}
"happy-dom": "{% endraw %}{{ happy_dom_version }}{% raw %}",{% endraw %}{% if frontend_uses_graphql %}{% raw %}
"mock-apollo-client": "^1.4.0",{% endraw %}{% endif %}{% raw %}
"playwright": "{% endraw %}{{ playwright_version }}{% raw %}",
"playwright-core": "{% endraw %}{{ playwright_version }}{% raw %}",
"postcss": "^8.5.3",
"tailwindcss": "^4.0.14",
"vitest": "^3.0.9",
"vue-eslint-parser": "^10.1.1",
"vue-tsc": "^2.2.8"
"tailwindcss": "{% endraw %}{{ tailwindcss_version }}{% raw %}",
"typescript": "{% endraw %}{{ typescript_version }}{% raw %}",
"vitest": "{% endraw %}{{ vitest_version }}{% raw %}",
"vue-eslint-parser": "{% endraw %}{{ vue_eslint_parser_version }}{% raw %}",
"vue-tsc": "{% endraw %}{{ vue_tsc_version }}{% raw %}"
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick | 🔵 Trivial

Nuxt/GraphQL dependency matrix is reasonable; confirm version alignment and module usage

The dependency set aligns with the rest of the PR (Nuxt, UI, fonts/icon, color‑mode, Vitest, Playwright, GraphQL tooling, etc.) and the use of Jinja placeholders gives you flexibility across projects.

A few alignment points to double‑check:

  • @nuxt/schema using {{ nuxt_version }}: ensure the @nuxt/schema version that matches your Nuxt 4 target actually exists and is compatible.
  • @nuxt/test-utils vs "@nuxt/test-utils/module" in nuxt.config.ts.jinja: confirm the pinned version exposes that module entry point in the version you template.
  • When frontend_uses_graphql is true, verify that @nuxtjs/apollo, graphql, and @vue/apollo-composable versions are mutually compatible and that the Nuxt module is registered in nuxt.config.ts.jinja as needed.
  • vue and vue-router versions templated here should be in the range supported by the chosen Nuxt 4 version.

Overall, this looks like a solid starting matrix; it just needs version compatibility checks against the specific Nuxt/Vue/GraphQL stack you intend to generate.

Please validate the exact versions you substitute for {{ nuxt_version }}, {{ vue_version }}, {{ vue_router_version }}, {{ nuxt_apollo_version }}, and related GraphQL packages against their official compatibility tables/documentation for Nuxt 4.

🤖 Prompt for AI Agents
template/{{ app_name }}_app/package.json.jinja lines 22-68: the review asks you
to validate and align all templated dependency versions with Nuxt 4/Vue
compatibility—verify that the value substituted for {{ nuxt_version }} is a
valid release that also provides the matching @nuxt/schema version, ensure {{
vue_version }} and {{ vue_router_version }} are within the supported range for
that Nuxt 4 release, confirm @nuxt/test-utils at the pinned version exposes the
"/module" entry if you reference it in nuxt.config.ts.jinja, and when
frontend_uses_graphql is true verify mutual compatibility between {{
nuxt_apollo_version }}, graphql, @vue/apollo-composable and that the
@nuxtjs/apollo module is registered in nuxt.config.ts.jinja; fix by updating the
Jinja defaults or documentation to only emit compatible version tuples (or add
conditional logic/comments in the template) and adjust nuxt.config.ts.jinja to
register the Apollo module or change imports to match the tested test-utils
entrypoint.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR migrates the project template to Nuxt 4's folder structure and configuration format, updating the project to be compatible with the latest Nuxt framework version.

Key Changes:

  • Restructured application to use Nuxt 4's app/ directory convention with assets, layouts, and pages organized within it
  • Updated nuxt.config.ts to set compatibilityVersion: 4 and configured modern module setup including @nuxt/ui, @nuxt/eslint, and @nuxt/test-utils
  • Migrated ESLint configuration to the new flat config format (eslint.config.mjs) with integrated vitest plugin support for test files

Reviewed changes

Copilot reviewed 7 out of 12 changed files in this pull request and generated no comments.

Show a summary per file
File Description
nuxt.config.ts.jinja Updated to Nuxt 4 compatibility mode with future.compatibilityVersion set to 4, configured modern modules and conditional Apollo GraphQL support
package.json.jinja Updated dependencies to Nuxt 4-compatible versions including @nuxt/ui ^4.2.1, nuxt ^4.2.0, and new packages like @nuxt/icon and @nuxt/fonts
eslint.config.mjs Migrated from legacy ESLint config to flat config format with vitest plugin integration for test file linting
tsconfig.json Simplified configuration extending from .nuxt/tsconfig.json with custom typeRoots
app/app.config.ts Added UI theme configuration with comprehensive color palette for @nuxt/ui components
app/assets/css/main.css Updated CSS imports to use Tailwind CSS v4 syntax with theme(static) and @nuxt/ui imports
app/layouts/default.vue Created default layout using UApp component wrapper for consistent UI theming
app/pages/index.vue Added basic index page as entry point for the application
types/nuxt.config.d.ts Added TypeScript declaration to extend NuxtConfig schema with apollo client types

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ejfine ejfine merged commit c5d8fd7 into main Nov 29, 2025
7 checks passed
@ejfine ejfine deleted the nuxt4 branch November 29, 2025 02:24
@coderabbitai coderabbitai bot mentioned this pull request Dec 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants