Once I uninstalled the react-native-cli
, I attempted to start a React Native project with a typescript template using the following command:
npx react-native init MyApp --template react-native-template-typescript
However, I encountered an error message:
warning jest > jest-cli > jest-config > jest-environment-jsdom > jsdom
[email protected]: use String.prototype.padStart() error An unexpected error occurred: ": Not found".info If you think this is a bug, please open .....
[1/2] Removing module react-native-template-react-native-template-typescript...
error This module isn't specified in a package.json file.
info Visit https://yarnpkg.com/en/docs/cli/remove for documentation about this command. warn Failed to clean up template temp files in node_modules/react-native-template-react-native-template-typescript. This is not a critical error, you can work on your app.
(node:8548) UnhandledPromiseRejectionWarning: Error: Command failed: yarn add react-native-template-react-native-template-typescript