Skip to content

Commit

Permalink
refactor(docs): add package manager options (#3731)
Browse files Browse the repository at this point in the history
Co-authored-by: Maharshi Alpesh <[email protected]>
  • Loading branch information
macci001 and Maharshi Alpesh authored Sep 10, 2024
1 parent 4ac7674 commit 5fd001c
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions apps/docs/content/docs/guide/installation.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,21 @@ Requirements:

Using the CLI is now the easiest way to start a NextUI project. You can initialize your project and add components directly via the CLI:

```codeBlock bash
npm install -g nextui-cli
```
<Steps>

<Spacer y={4}/>
### Installation
Execute one of the following commands in your terminal:
<PackageManagers
commands={{
npm: "npm install -g nextui-cli",
yarn: "yarn add -g nextui-cli",
pnpm: "pnpm add -g nextui-cli",
bun: "bun add -g nextui-cli",
}}
/>

### Initialization and Starting the App
Initialize the project by using the `init` command.
```codeBlock bash
nextui init my-nextui-app
```
Expand All @@ -48,6 +57,7 @@ Start the local server:
npm run dev
```

### Adding the Components
Once your NextUI project is ready to develop, you can add individual components using the CLI. For example, to add a button component:

```codeBlock bash
Expand Down Expand Up @@ -92,6 +102,8 @@ Filtered results for: Enter something to filter
◯ code
```

</Steps>

## Manual Installation

If you prefer not to use the CLI, you may try either global installation or individual installation to set up NextUI in your project:
Expand Down

0 comments on commit 5fd001c

Please sign in to comment.