Guide
Start a new project with the template
sh
$ npx deegit https://git.weconstudio.it/we/nuxt-template.git <project-name>
or add it to an existing project
sh
$ yarn add https://git.weconstudio.it/we/nuxt.git
Add @we/nuxt to modules section of nuxt.config.js
js
{
modules: [
'@we/nuxt'
],
ssr: false,
devtools: { enabled: true },
compatibilityDate: '2024-08-09',
i18n: {
lazy: true,
defaultLocale: 'it',
strategy: 'no_prefix',
vueI18n: './i18n.config.ts',
locales: [
{
code: 'it',
name: 'Italiano',
},
],
},
notivue: {
position: 'top-right',
enqueue: true,
limit: Number.POSITIVE_INFINITY,
},
sanctum: {
globalMiddleware: {
enabled: true,
allow404WithoutAuth: true,
},
},
we: {
notify: {
enabled: true,
css: true,
legacy: true,
},
api: {
baseUrl: process.env.BASE_URL,
apiSuffix: 'api/backoffice/',
endpoints: [
'https://api.test.com',
'https://staging.api.test.com'
],
},
},
}
INFO
You can find more information for each module in the corresponding section