Skip to content

Commit

Permalink
Merge pull request #18 from laruiss/feat/use-vue-dsfr-v6
Browse files Browse the repository at this point in the history
Feat/use vue dsfr v6
  • Loading branch information
laruiss authored Sep 5, 2024
2 parents 20d1f0a + b1e67d4 commit 4031bda
Show file tree
Hide file tree
Showing 36 changed files with 934 additions and 375 deletions.
936 changes: 870 additions & 66 deletions package-lock.json

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,24 +25,24 @@
"license": "ISC",
"main": "index.js",
"overrides": {
"graceful-fs": "^4.2.10"
"graceful-fs": "^4.2.11"
},
"repository": {
"type": "git",
"url": "git+https://github.com/laruiss/create-vue-dsfr.git"
},
"scripts": {},
"dependencies": {
"adm-zip": "^0.5.10",
"archiver": "^5.3.1",
"kolorist": "^1.6.0",
"minimist": "^1.2.7",
"adm-zip": "^0.5.16",
"archiver": "^5.3.2",
"kolorist": "^1.8.0",
"minimist": "^1.2.8",
"ohmyfetch": "^0.4.21",
"prompts": "^2.4.2",
"rimraf": "^3.0.2"
"rimraf": "^6.0.1"
},
"devDependencies": {
"@types/node": "^18.11.18",
"prettier": "^2.8.1"
"@types/node": "^18.19.50",
"prettier": "^2.8.8"
}
}
101 changes: 0 additions & 101 deletions template-nuxt3-ts-complet/.eslintrc-auto-import.json

This file was deleted.

2 changes: 0 additions & 2 deletions template-nuxt3-ts-complet/client/auto-imports.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,7 @@ declare module 'vue' {
interface GlobalComponents {}
interface ComponentCustomProperties {
readonly EffectScope: UnwrapRef<typeof import('vue')['EffectScope']>
readonly OhVueIcon: UnwrapRef<typeof import('oh-vue-icons')['OhVueIcon']>
readonly acceptHMRUpdate: UnwrapRef<typeof import('pinia')['acceptHMRUpdate']>
readonly addIcons: UnwrapRef<typeof import('oh-vue-icons')['addIcons']>
readonly afterAll: UnwrapRef<typeof import('vitest')['afterAll']>
readonly afterEach: UnwrapRef<typeof import('vitest')['afterEach']>
readonly assert: UnwrapRef<typeof import('vitest')['assert']>
Expand Down
6 changes: 0 additions & 6 deletions template-nuxt3-ts-complet/client/icons.ts

This file was deleted.

4 changes: 2 additions & 2 deletions template-nuxt3-ts-complet/client/layouts/default.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ const quickLinks = [
{
label: 'Accueil',
to: '/',
icon: 'ri-home-2-line',
icon: { name: 'ri-home-2-line', ssr: true },
},
{
label: 'À propos',
to: '/apropos',
icon: 'ri-flag-line',
icon: { name: 'ri-flag-line', ssr: true },
},
]
Expand Down
11 changes: 5 additions & 6 deletions template-nuxt3-ts-complet/client/pages/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,11 @@ useHead({ title: 'Page d’accueil - Gabarit de démarrage VueDsfr' })
 (<code>&lt;span class="fr-icon-ancient-gate-fill" /></code>)
</p>
<p>
<VIcon name="ri-flag-line" /> <!-- Icône OhVueIcon -->
 (<code>&lt;VIcon name="ri-flag-line" /></code>)
</p>
<p>
<OhVueIcon name="ri-flag-line" /> <!-- Icône OhVueIcon -->
 (<code>&lt;OhVueIcon name="ri-flag-line" /></code>)
<VIcon
ssr
name="ri-flag-line"
/> <!-- Icône @iconify -->
 (<code>&lt;VIcon ssr name="ri-flag-line" /></code>)
</p>
</div>
</template>
8 changes: 0 additions & 8 deletions template-nuxt3-ts-complet/client/plugins/vue-dsfr.ts

This file was deleted.

8 changes: 0 additions & 8 deletions template-nuxt3-ts-complet/icons.ts

This file was deleted.

11 changes: 2 additions & 9 deletions template-nuxt3-ts-complet/nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import { defineNuxtConfig } from 'nuxt/config'

import * as icons from './icons'

// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
app: {
Expand Down Expand Up @@ -36,13 +34,6 @@ export default defineNuxtConfig({
'@nuxt/test-utils/module',
'vue-dsfr-nuxt-module',
],
runtimeConfig: {
public: {
vueDsfr: {
icons: Object.values(icons),
},
},
},
css: [
'@gouvfr/dsfr/dist/core/core.main.min.css',
'@gouvfr/dsfr/dist/component/component.main.min.css',
Expand All @@ -57,4 +48,6 @@ export default defineNuxtConfig({
'**/*.spec.*',
'**/*.cy.*',
],

compatibilityDate: '2024-09-05',
})
25 changes: 12 additions & 13 deletions template-nuxt3-ts-complet/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
"scripts": {
"build": "nuxt build",
"dev": "nuxt dev",
"format": "eslint . --fix",
"format": "eslint client server tests --fix",
"generate": "nuxt generate",
"lint": "eslint .",
"lint": "eslint client server tests",
"preview": "nuxt preview",
"test": "run-s test:unit test:e2e",
"test:unit": "vitest run",
Expand All @@ -17,33 +17,32 @@
"e2e:web": "npx playwright show-report"
},
"dependencies": {
"@gouvfr/dsfr": "^1.11.2",
"@gouvminint/vue-dsfr": "^5.19.3",
"nuxt": "^3.13.0",
"oh-vue-icons": "^1.0.0-rc3",
"vue": "^3.4.38",
"vue-dsfr-nuxt-module": "^1.1.2",
"@gouvfr/dsfr": "~1.12.1",
"@gouvminint/vue-dsfr": "^6.0.0",
"nuxt": "^3.13.1",
"vue": "^3.5.1",
"vue-dsfr-nuxt-module": "^2.0.0",
"vue-router": "^4.4.3"
},
"devDependencies": {
"@antfu/eslint-config": "^3.0.0",
"@antfu/eslint-config": "^3.2.0",
"@nuxt/test-utils": "^3.14.1",
"@playwright/test": "^1.46.1",
"@testing-library/jest-dom": "^6.5.0",
"@testing-library/user-event": "^14.5.2",
"@testing-library/vue": "^8.1.0",
"@types/jsdom": "^21.1.7",
"@types/node": "^20.16.2",
"@types/node": "^20.16.5",
"@vue/test-utils": "^2.4.6",
"eslint": "9.0.0-rc.0",
"happy-dom": "^15.4.2",
"happy-dom": "^15.7.3",
"npm-run-all2": "^6.2.2",
"nuxt-vitest": "^0.11.5",
"playwright-core": "^1.46.1",
"typescript": "^5.4.3",
"typescript": "^5.5.4",
"unplugin-auto-import": "^0.18.2",
"vitest": "^2.0.5",
"vitest-environment-nuxt": "^1.0.1",
"vue-tsc": "^2.1.2"
"vue-tsc": "^2.1.6"
}
}
3 changes: 0 additions & 3 deletions template-nuxt3-ts-complet/vitest.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { defineVitestConfig } from '@nuxt/test-utils/config'
import AutoImport from 'unplugin-auto-import/vite'
import {
ohVueIconAutoimportPreset,
vueDsfrAutoimportPreset,
} from '@gouvminint/vue-dsfr'

Expand All @@ -24,8 +23,6 @@ export default defineVitestConfig({
'vitest',
// @ts-expect-error ts2740
vueDsfrAutoimportPreset,
// @ts-expect-error ts2740
ohVueIconAutoimportPreset,
],
vueTemplate: true,
dts: './auto-imports.d.ts',
Expand Down
6 changes: 0 additions & 6 deletions template-nuxt3-ts-simple/client/icons.ts

This file was deleted.

4 changes: 2 additions & 2 deletions template-nuxt3-ts-simple/client/layouts/default.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ const quickLinks = [
{
label: 'Accueil',
to: '/',
icon: 'ri-home-2-line',
icon: { name: 'ri-home-2-line', ssr: true },
},
{
label: 'À propos',
to: '/apropos',
icon: 'ri-flag-line',
icon: { name: 'ri-flag-line', ssr: true },
},
]
Expand Down
11 changes: 5 additions & 6 deletions template-nuxt3-ts-simple/client/pages/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,11 @@ useHead({ title: 'Page d’accueil - Gabarit de démarrage VueDsfr' })
 (<code>&lt;span class="fr-icon-ancient-gate-fill" /></code>)
</p>
<p>
<VIcon name="ri-flag-line" /> <!-- Icône OhVueIcon -->
 (<code>&lt;VIcon name="ri-flag-line" /></code>)
</p>
<p>
<OhVueIcon name="ri-flag-line" /> <!-- Icône OhVueIcon -->
 (<code>&lt;OhVueIcon name="ri-flag-line" /></code>)
<VIcon
ssr
name="ri-flag-line"
/> <!-- Icône Iconify -->
 (<code>&lt;VIcon ssr name="ri-flag-line" /></code>)
</p>
</div>
</template>
8 changes: 0 additions & 8 deletions template-nuxt3-ts-simple/client/plugins/vue-dsfr.ts

This file was deleted.

Loading

0 comments on commit 4031bda

Please sign in to comment.