react-native-builder-bob
react-native-builder-bob copied to clipboard
Bootstrapping new project created from create-react-native-library does not work
Environment
Nothing special, just issued the following command from terminal
npx create-react-native-library@latest react-native-components
cd react-native-components
yarn
Description
The script will fail with error:
....
✔ Wrote definition files to lib/typescript
$ yarn --cwd example pods
error Command "pods" not found.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Whenever i try yarn example ios
✔ It looks like you're trying to use TypeScript but don't have the required dependencies installed. Would you like to install @types/react? … yes
✔ Installed @types/react@~17.0.21
It looks like you're trying to use TypeScript but don't have the required dependencies installed.
Please install @types/react by running:
yarn add --dev @types/react@~17.0.21
If you're not using TypeScript, please remove the TypeScript files from your project and delete the tsconfig.json.
It will present this error no matter if you installed the @types/react library.
Can you try again with the latest version?
Can you try again with the latest version?
Yes, it is working now, thanks! Can you add background color white in example build in future?, because in example project start with black screen without result text.
Can you try again with the latest version?
How can I fix my current project with previous version?
How can I fix my current project with previous version?
You can generate a new project and copy over the files
@Splicer97
- update "scripts" section in
package.jsonfiles in root and in example folder from generated new project. - update Podfile from generated new project.
- Update metro.config.js
- Detele all *.lock files and Podfile.lock