mirror of
https://github.com/ArthurDanjou/website-old.git
synced 2026-01-30 19:57:54 +01:00
Rebase old template to new
This commit is contained in:
34
settings/Arch.ts
Normal file
34
settings/Arch.ts
Normal file
@@ -0,0 +1,34 @@
|
||||
const srcDir = 'src'
|
||||
|
||||
const dir = {
|
||||
assets: 'assets',
|
||||
layouts: 'layouts',
|
||||
middleware: 'middlewares',
|
||||
pages: 'pages',
|
||||
static: 'static',
|
||||
store: 'store',
|
||||
}
|
||||
|
||||
const build = {
|
||||
extractCss: true,
|
||||
}
|
||||
|
||||
const generate = {
|
||||
interval: 2000,
|
||||
}
|
||||
|
||||
const pageTransition = {
|
||||
name: 'page',
|
||||
mode: 'out-in',
|
||||
}
|
||||
|
||||
const target = 'server'
|
||||
|
||||
const server = {
|
||||
host: '0.0.0.0',
|
||||
port: 3333
|
||||
}
|
||||
|
||||
const buildDir = 'build'
|
||||
|
||||
export default { srcDir, dir, generate, build, pageTransition, target, server, buildDir }
|
||||
2
settings/Build.ts
Normal file
2
settings/Build.ts
Normal file
@@ -0,0 +1,2 @@
|
||||
// Build Configuration: https://go.nuxtjs.dev/config-build
|
||||
export default {}
|
||||
16
settings/BuildModules.ts
Normal file
16
settings/BuildModules.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
// Modules for dev and build (recommended): https://go.nuxtjs.dev/config-modules
|
||||
const color_mode = {
|
||||
preference: 'system',
|
||||
fallback: 'light',
|
||||
classPrefix: '',
|
||||
classSuffix: '',
|
||||
}
|
||||
|
||||
export default [
|
||||
'@nuxt/typescript-build',
|
||||
'@nuxtjs/composition-api',
|
||||
'@nuxt/postcss8',
|
||||
'nuxt-windicss',
|
||||
'nuxt-vite',
|
||||
['@nuxtjs/color-mode', color_mode],
|
||||
]
|
||||
39
settings/Head.ts
Normal file
39
settings/Head.ts
Normal file
@@ -0,0 +1,39 @@
|
||||
// Global page headers: https://go.nuxtjs.dev/config-head
|
||||
const params = {
|
||||
title: 'nuxt-ts-app',
|
||||
color: '#0DA5FF',
|
||||
image: '/images/image.jpg',
|
||||
url: 'https://my-domain.com',
|
||||
favicon: {
|
||||
type: 'image/jpg',
|
||||
href: '/favicon.jpg',
|
||||
},
|
||||
description:
|
||||
'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. ',
|
||||
}
|
||||
|
||||
export default {
|
||||
htmlAttrs: { lang: 'fr-FR' },
|
||||
title: params.title,
|
||||
meta: [
|
||||
{ charset: 'utf-8' },
|
||||
{ lang: 'fr-FR' },
|
||||
{ name: 'viewport', content: 'width=device-width, initial-scale=1' },
|
||||
{ hid: 'description', name: 'description', content: params.description },
|
||||
|
||||
/**
|
||||
* Open graph
|
||||
* See : https://ogp.me/
|
||||
*/
|
||||
{ hid: 'og:type', name: 'og:type', content: 'website' },
|
||||
{ hid: 'og:url', name: 'og:url', content: params.url },
|
||||
{ hid: 'og:title', name: 'og:title', content: params.title },
|
||||
{ hid: 'og:site_name', name: 'og:site_name', content: params.title },
|
||||
{ hid: 'og:locale', name: 'og:locale', content: 'fr' },
|
||||
{ hid: 'og:image', name: 'og:image', content: params.image },
|
||||
|
||||
{ name: 'msapplication-TileColor', content: params.color },
|
||||
{ name: 'theme-color', content: params.color },
|
||||
],
|
||||
link: [{ rel: 'icon', type: params.favicon.type, href: params.favicon.href }],
|
||||
}
|
||||
54
settings/Modules.ts
Normal file
54
settings/Modules.ts
Normal file
@@ -0,0 +1,54 @@
|
||||
const axios = {
|
||||
credentials: true,
|
||||
baseURL: process.env.NODE_ENV == 'production'
|
||||
? 'https://my-domain.fr'
|
||||
: 'http://localhost:3333',
|
||||
}
|
||||
|
||||
const i18n = {
|
||||
locales: [
|
||||
{
|
||||
code: 'en',
|
||||
name: 'English',
|
||||
iso: 'en-EN',
|
||||
file: 'en-EN.ts',
|
||||
},
|
||||
{
|
||||
code: 'fr',
|
||||
iso: 'fr-FR',
|
||||
file: 'fr-FR.ts',
|
||||
name: 'Français'
|
||||
},
|
||||
],
|
||||
strategy: 'no_prefix',
|
||||
defaultLocale: 'en',
|
||||
langDir: 'locales/',
|
||||
lazy: true,
|
||||
seo: true,
|
||||
vueI18n: {
|
||||
fallbackLocale: 'en',
|
||||
},
|
||||
}
|
||||
|
||||
const content = {
|
||||
apiPrefix: 'api',
|
||||
nestedProperties: ['categories.slug'],
|
||||
markdown: {
|
||||
prism: {
|
||||
theme: 'prism-themes/themes/prism-darcula.css'
|
||||
},
|
||||
remarkPlugins: [
|
||||
'remark-squeeze-paragraphs',
|
||||
'remark-slug',
|
||||
'remark-autolink-headings',
|
||||
'remark-external-links',
|
||||
'remark-footnotes',
|
||||
],
|
||||
}
|
||||
}
|
||||
|
||||
export default [
|
||||
['@nuxtjs/axios', axios],
|
||||
['nuxt-i18n', i18n],
|
||||
['@nuxt/content', content],
|
||||
]
|
||||
2
settings/Plugins.ts
Normal file
2
settings/Plugins.ts
Normal file
@@ -0,0 +1,2 @@
|
||||
// Plugins to run before rendering page: https://go.nuxtjs.dev/config-plugins
|
||||
export default []
|
||||
2
settings/Style.ts
Normal file
2
settings/Style.ts
Normal file
@@ -0,0 +1,2 @@
|
||||
// Global CSS: https://go.nuxtjs.dev/config-css
|
||||
export default []
|
||||
Reference in New Issue
Block a user