From af80c327bada689767189131912888d3b6092c6a Mon Sep 17 00:00:00 2001 From: Katerina Skroumpelou Date: Fri, 10 Nov 2023 16:43:03 +0200 Subject: [PATCH] fix(nuxt): import defineNuxtConfig function in nuxt.config.ts --- .../application/__snapshots__/application.spec.ts.snap | 5 +++++ .../src/generators/application/files/nuxt.config.ts__tmpl__ | 1 + 2 files changed, 6 insertions(+) diff --git a/packages/nuxt/src/generators/application/__snapshots__/application.spec.ts.snap b/packages/nuxt/src/generators/application/__snapshots__/application.spec.ts.snap index 6a136acb0a880..f7afb5b95c1c9 100644 --- a/packages/nuxt/src/generators/application/__snapshots__/application.spec.ts.snap +++ b/packages/nuxt/src/generators/application/__snapshots__/application.spec.ts.snap @@ -28,6 +28,7 @@ exports[`app generated files content - as-provided general application should co exports[`app generated files content - as-provided general application should configure nuxt correctly 1`] = ` "import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin'; +import { defineNuxtConfig } from 'nuxt/config'; // https://nuxt.com/docs/api/configuration/nuxt-config export default defineNuxtConfig({ @@ -203,6 +204,7 @@ exports[`app generated files content - as-provided general application should cr exports[`app generated files content - as-provided styles setup should configure css 1`] = ` "import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin'; +import { defineNuxtConfig } from 'nuxt/config'; // https://nuxt.com/docs/api/configuration/nuxt-config export default defineNuxtConfig({ @@ -224,6 +226,7 @@ export default defineNuxtConfig({ exports[`app generated files content - as-provided styles setup should configure less 1`] = ` "import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin'; +import { defineNuxtConfig } from 'nuxt/config'; // https://nuxt.com/docs/api/configuration/nuxt-config export default defineNuxtConfig({ @@ -245,6 +248,7 @@ export default defineNuxtConfig({ exports[`app generated files content - as-provided styles setup should configure scss 1`] = ` "import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin'; +import { defineNuxtConfig } from 'nuxt/config'; // https://nuxt.com/docs/api/configuration/nuxt-config export default defineNuxtConfig({ @@ -266,6 +270,7 @@ export default defineNuxtConfig({ exports[`app generated files content - as-provided styles setup should not configure styles 1`] = ` "import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin'; +import { defineNuxtConfig } from 'nuxt/config'; // https://nuxt.com/docs/api/configuration/nuxt-config export default defineNuxtConfig({ diff --git a/packages/nuxt/src/generators/application/files/nuxt.config.ts__tmpl__ b/packages/nuxt/src/generators/application/files/nuxt.config.ts__tmpl__ index 7ddade069f194..95112345a1481 100644 --- a/packages/nuxt/src/generators/application/files/nuxt.config.ts__tmpl__ +++ b/packages/nuxt/src/generators/application/files/nuxt.config.ts__tmpl__ @@ -1,4 +1,5 @@ import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin'; +import { defineNuxtConfig } from 'nuxt/config'; // https://nuxt.com/docs/api/configuration/nuxt-config export default defineNuxtConfig({