Skip to content

Unable to run expo example project: Unable to resolve "react" from "example/src/App.tsx" #687

@AnnaSacuteTAG

Description

@AnnaSacuteTAG

Description

Can not run the example expo project after create a new library with command npx create-react-native-library@latest awesome-library in version 0.44.1

Steps to reproduce:

  • Create a new library using the command: npx create-react-native-library@latest awesome-library
  • Enter inside folder: cd awesome-library
  • Install dependencies: npm i
  • Enter inside example folder: cd example
  • Start metro: npm start
  • See error on console

Image

Packages

  • create-react-native-library
  • react-native-builder-bob

Selected options

✔ What is the name of the npm package? … ui-library
✔ What is the description for the package? … Test ui library component creation
✔ What is the name of package author? … Anna
✔ What is the email address for the package author? … anaclaudiasacute75@gmail.com
✔ What is the URL for the package author? … https://github.com/AnaClaudiaSac
✔ What is the URL for the repository? … https://github.com/AnaClaudiaSac/ui-library
✔ What type of library do you want to develop? › JavaScript library
✔ Project created successfully at ui-library!

Link to repro

N/A

Environment

MacOS: 12.7.6
Node: 22.11.0
create-react-native-library: 0.44.1

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions