Ynex – Nuxt3 Premium Bootstrap-5 Admin Template

Creating a Pages

You can generate new pages in Nuxt.js using the nuxt generate command


# Generates `pages/about.vue`
npx nuxi add page about

# Generates `pages/category/[id].vue`
npx nuxi add page "category/[id]"
										
Creating a Component

To create components using the Nuxt.js CLI (Command Line Interface), you can use the generate command. Here's how you can create components:


Creating a component using the Nuxt CLI

To create a component using the CLI:

npx nuxi add component YourComponentName
By default, this command creates the following:
  • YourComponentName.vue
Where <YourComponentName> is the name of your component.

Creating a Custom Commands

In Nuxt.js 3, you can generate custom commands using the @nuxt/cli package. For example, to generate a custom command:

npx nuxt create command my-custom-command