mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-30 11:47:55 +01:00
docs: use new nuxi module add command in installation (#1606)
Co-authored-by: Benjamin Canac <canacb1@gmail.com>
This commit is contained in:
@@ -27,14 +27,7 @@ Read more on [ui.nuxt.com](https://ui.nuxt.com)
|
|||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# npm
|
npx nuxi@latest module add ui
|
||||||
npm install @nuxt/ui
|
|
||||||
# yarn
|
|
||||||
yarn add @nuxt/ui
|
|
||||||
# pnpm
|
|
||||||
pnpm add @nuxt/ui
|
|
||||||
# bun
|
|
||||||
bun add @nuxt/ui
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Then, register the module in your `nuxt.config.ts`:
|
Then, register the module in your `nuxt.config.ts`:
|
||||||
|
|||||||
@@ -61,9 +61,7 @@ const items = [{
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="flex flex-col items-center">
|
<div class="flex flex-col items-center">
|
||||||
<code>$ npm i @nuxt/ui</code>
|
<code>$ npx nuxi@latest module add ui</code>
|
||||||
<code>$ yarn add @nuxt/ui</code>
|
|
||||||
<code>$ pnpm add @nuxt/ui</code>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</UAccordion>
|
</UAccordion>
|
||||||
|
|||||||
@@ -5,29 +5,13 @@ description: 'Learn how to install and configure Nuxt UI in your application.'
|
|||||||
|
|
||||||
## Setup
|
## Setup
|
||||||
|
|
||||||
1. Install `@nuxt/ui` dependency to your project:
|
1. Add `@nuxt/ui` module to your project:
|
||||||
|
|
||||||
::code-group
|
```bash
|
||||||
|
npx nuxi@latest module add ui
|
||||||
```bash [pnpm]
|
|
||||||
pnpm add @nuxt/ui
|
|
||||||
```
|
```
|
||||||
|
|
||||||
```bash [yarn]
|
2. Add it to the `modules` section in your `nuxt.config.ts`:
|
||||||
yarn add @nuxt/ui
|
|
||||||
```
|
|
||||||
|
|
||||||
```bash [npm]
|
|
||||||
npm install @nuxt/ui
|
|
||||||
```
|
|
||||||
|
|
||||||
```bash [bun]
|
|
||||||
bun add @nuxt/ui
|
|
||||||
```
|
|
||||||
|
|
||||||
::
|
|
||||||
|
|
||||||
2. Add it to your `modules` section in your `nuxt.config`:
|
|
||||||
|
|
||||||
```ts [nuxt.config.ts]
|
```ts [nuxt.config.ts]
|
||||||
export default defineNuxtConfig({
|
export default defineNuxtConfig({
|
||||||
|
|||||||
@@ -31,10 +31,11 @@
|
|||||||
readonly
|
readonly
|
||||||
autocomplete="off"
|
autocomplete="off"
|
||||||
icon="i-heroicons-command-line"
|
icon="i-heroicons-command-line"
|
||||||
input-class="select-none"
|
class="w-72"
|
||||||
|
input-class="focus:ring-1 focus:ring-gray-300 dark:focus:ring-gray-700"
|
||||||
aria-label="Install @nuxt/ui"
|
aria-label="Install @nuxt/ui"
|
||||||
size="lg"
|
size="lg"
|
||||||
:ui="{ base: 'disabled:cursor-default', icon: { trailing: { pointer: '' } } }"
|
:ui="{ icon: { trailing: { pointer: '' } } }"
|
||||||
>
|
>
|
||||||
<template #trailing>
|
<template #trailing>
|
||||||
<UButton
|
<UButton
|
||||||
@@ -435,7 +436,7 @@ useSeoMeta({
|
|||||||
twitterImage: 'https://ui.nuxt.com/social-card.png'
|
twitterImage: 'https://ui.nuxt.com/social-card.png'
|
||||||
})
|
})
|
||||||
|
|
||||||
const source = ref('npm i @nuxt/ui')
|
const source = ref('npx nuxi@latest module add ui')
|
||||||
const sectionRef = ref()
|
const sectionRef = ref()
|
||||||
const demoRef = ref()
|
const demoRef = ref()
|
||||||
const start = ref(0)
|
const start = ref(0)
|
||||||
|
|||||||
Reference in New Issue
Block a user