Skip to content

Commit ed5f7ac

Browse files
Documentation updates from Promptless
1 parent 5939fa8 commit ed5f7ac

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

fern/products/cli-api-reference/pages/cli-get-started.mdx

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,50 @@ fern generate --group ts-sdk # Generate specific SDK group
3636
The "default SDK group" refers to the group marked as default in your `generators.yml`. Learn more about [default groups](/learn/sdks/introduction/configuration).
3737
</Note>
3838

39+
## Performance Optimization
40+
41+
For improved performance, you can install Fern CLI as a local project dependency:
42+
43+
<Steps>
44+
<Step title="Install as project dependency">
45+
46+
Add `fern-api` to your project dependencies:
47+
48+
```bash
49+
npm install fern-api
50+
```
51+
52+
</Step>
53+
54+
<Step title="Update configuration">
55+
56+
In your `fern.config.json`, set the version to `*`:
57+
58+
```json fern.config.json
59+
{
60+
"version": "*"
61+
}
62+
```
63+
64+
</Step>
65+
66+
<Step title="Run via package manager">
67+
68+
Use npm to run Fern commands:
69+
70+
```bash
71+
npm fern check # Validate API definition
72+
npm fern --version # Check CLI version
73+
npm fern generate # Generate outputs
74+
```
75+
76+
</Step>
77+
</Steps>
78+
79+
<Tip>
80+
This approach uses your project-specific version of Fern CLI, which can improve performance and ensure consistency across your team.
81+
</Tip>
82+
3983
## Common Workflows
4084

4185
<AccordionGroup>

0 commit comments

Comments
 (0)