native-mate add
Fetch one or more components from the registry and write them into your project.
Usage
bash
1
npx native-mate add <component> [components...] [options]Examples
bash
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Add a single component
npx native-mate add button
# Add multiple at once
npx native-mate add button card input badge avatar
# Use a custom registry
npx native-mate add button --registry https://my-registry.dev
# Overwrite existing files
npx native-mate add button --overwrite
# Add all available components
npx native-mate add --all
# Interactive mode — no arguments opens a multi-select picker
npx native-mate addOptions
| Flag | Description |
|---|---|
| -a, --all | Add all available components at once |
| -r, --registry <url> | Use a custom registry URL instead of the default |
| --overwrite | Overwrite existing component files if they differ |
What it does
- Reads
native-mate.jsonto find your components directory - Fetches the component JSON from the registry
- Resolves and installs component dependencies recursively
- Writes component source files to your project
- Installs any required npm packages via your package manager