Nuxt Installation
Prerequisites
- Node.js version 20.11 or higher.
- VSCode is recommended, along with the official Vue extension.
- PNPM is recommended.
Skip More Nuxt Configuration here.
Installation
sh
$ pnpm add -D pergel
sh
$ npm add -D pergel
sh
$ yarn add -D pergel
sh
$ bun add -D pergel
Setup Wizard
Get started with Pergel by running the following command: This will create a pergel.ts
file in your project .config
folder.
sh
$ pnpm pergel init
sh
$ npm pergel init
sh
$ yarn pergel init
sh
$ bun pergel init
Usage
- Go to
nuxt.config.ts
and add the following code:
ts
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
modules: [
'pergel/nuxt',
],
})
- The prepare command creates a .nuxt directory in your application and generates types.
sh
$ pnpm nuxt prepare
sh
$ npm nuxt prepare
sh
$ yarn nuxt prepare
sh
$ bun nuxt prepare
- Crete project with the following command:
ts
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
modules: [
'pergel/nuxt',
],
pergel: {
projects: {
// changeName -> Please change this to your project name camelCase
changeName: {
// ...modules and options
}
}
},
})
changeName
changeName
is the name of your project. Please change it to your project name.
- Generates types and
pergel
folder upgrade.
sh
$ pnpm nuxt prepare
sh
$ npm nuxt prepare
sh
$ yarn nuxt prepare
sh
$ bun nuxt prepare
INFO
Success! You have installed Pergel. Now you can start your project with Pergel. More Nuxt Configuration here.