Skip to content

Commit 5cb1766

Browse files
chore: readme (#22)
1 parent 5dfe504 commit 5cb1766

File tree

1 file changed

+29
-1
lines changed

1 file changed

+29
-1
lines changed

packages/nx/README.md

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99

1010
</div>
1111

12+
> Requires at least NativeScript CLI v8.x.x or higher. You can confirm your CLI version by running `ns --version`.
13+
1214
## Table of Contents
1315

1416
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
@@ -34,7 +36,10 @@
3436
### Create a new Nx workspace
3537

3638
```sh
37-
npx create-nx-workspace --cli=nx --preset=empty
39+
npx create-nx-workspace@latest --cli=nx --preset=empty
40+
41+
// If you run into any issue with latest Nx workspace version you may want to try the last known stable version with the following:
42+
npx [email protected] --cli=nx --preset=empty
3843
```
3944

4045
### Install NativeScript plugin
@@ -266,3 +271,26 @@ Which would generate a `buttons-nativescript` library.
266271
import { PrimaryButton } from '@myorg/buttons-nativescript';
267272
```
268273

274+
275+
## Using NativeScript plugins
276+
277+
NativeScript plugins can be used in Nx workspaces in one of the two following methods:
278+
279+
### Installing NativeScript plugins at app-level
280+
281+
If the plugin is needed by one app only, and not others, you can install it for the specific app:
282+
283+
```sh
284+
cd apps/<app-name>
285+
ns plugin add <plugin-name>
286+
```
287+
288+
### Installing NativeScript plugins at workspace-level
289+
290+
Alternatively, you can install the plugins at the workspace (root), so it is accesible to all your workspace apps:
291+
```sh
292+
npm install --save <plugin-name>
293+
```
294+
295+
### Known issues
296+
If a plugin contains platforms folder with native includes, the plugin must be added to app package.json at moment. https://github.com/NativeScript/nx/issues/17#issuecomment-841680719

0 commit comments

Comments
 (0)