Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an extra command to the troubleshooting guide for react-native-typescript #2954

Merged
merged 7 commits into from
Feb 7, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 12 additions & 5 deletions docs/typescript.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,18 @@ You can use the [TypeScript template][ts-template]:
npx react-native init MyApp --template react-native-template-typescript
```

> **Note:** If the above command is failing, you may have an old version of `react-native` or `react-native-cli` installed globally on your system. To fix the issue try uninstalling the CLI:
>
> - `npm uninstall -g react-native-cli` or `yarn global remove react-native-cli`
>
> and then run the `npx` command again.
:::note

If the above command is failing, you may have an old version of `react-native` or `react-native-cli` installed globally on your system. To fix the issue try uninstalling the CLI:

- `npm uninstall -g react-native-cli` or `yarn global remove react-native-cli`

and then run the `npx` command again.
Optionally, you can also use the command given below to get started with your template.

- `npx react-native --ignore-existing init MyApp --template react-native-template-typescript`

:::

You can use [Expo][expo] which has two TypeScript templates:

Expand Down