Unable to create to install dependencies and run example
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 42/100
- Issue-Typ
- Bug
- Klarheit
- Größtenteils klar
- Aktivitätsstatus
- Veraltet
- Tech-Stack
- javascript, node.js, react-native
- Bereich
- mobile-dev, tooling
Rechercherichtung
Reproduziere das Gerüst mit npx create-react-native-library@latest, führe yarn im generierten Projekt aus und führe anschließend yarn example android aus. Beginne mit example/metro.config.js und der Abhängigkeit react-native-monorepo-config und verwende die gemeldeten Yarn 1.22.22- und Node-Versionen; abgeschlossen bedeutet, dass die Abhängigkeiten ohne den Workaround installiert werden und das Android-Beispiel ohne den Metro-ESM-Fehler startet.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
➜ main nvm ls
v20.12.2
-> v20.19.5
main npx create-react-native-library@latest awesome-library
✔ What is the name of the npm package? … react-native-awesome-library
✔ What is the description for the package? … Testing
✔ What is the name of package author? … 0xSuryax
✔ What is the email address for the package author? … [email protected]
✔ What is the URL for the package author? … https://github.com/0xSuryax
✔ What is the URL for the repository? … https://github.com/0xSuryax/react-native-awesome-library
✔ What type of library do you want to develop? › Turbo module
✔ Project created successfully at awesome-library!
Get started with the project:
$ yarn
Run the example app on iOS:
$ yarn example ios
Run the example app on Android:
$ yarn example android
See CONTRIBUTING.md for more details. Good luck!
➜ awesome-library git:(main) yarn
Usage Error: The nearest package directory (/Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library) doesn't seem to be part of the project declared in /Users/qwerty.
- If /Users/qwerty isn't intended to be a project, remove any yarn.lock and/or package.json file there.
- If /Users/qwerty is intended to be a project, it might be that you forgot to list RESEARCH/MY_OWN_LIBS/main/awesome-library in its workspace configuration.
- Finally, if /Users/qwerty is fine and you intend RESEARCH/MY_OWN_LIBS/main/awesome-library to be treated as a completely separate project (not even a workspace), create an empty yarn.lock file in it.
$ yarn install [--json] [--immutable] [--immutable-cache] [--check-cache] [--inline-builds] [--mode #0]
then i created an empty yarn.lock file then i m able to install dependencies
then i run yarn example android and i got
➜ ~ /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/node_modules/.generated/launchPackager.command ; exit;
error Error loading Metro config at: /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/metro.config.js
require() of ES Module /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/node_modules/react-native-monorepo-config/index.js from /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/metro.config.js not supported.
Instead change the require of index.js in /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/metro.config.js to a dynamic import() which is available in all CommonJS modules.
Error [ERR_REQUIRE_ESM]: require() of ES Module /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/node_modules/react-native-monorepo-config/index.js from /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/metro.config.js not supported.
Instead change the require of index.js in /Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/metro.config.js to a dynamic import() which is available in all CommonJS modules.
at Object. (/Users/qwerty/RESEARCH/MY_OWN_LIBS/main/awesome-library/example/metro.config.js:3:29)
Process terminated. Press to close the window
➜ ~ yarn --version
1.22.22
- Vorherrschende Sprache
- JavaScript
- Sterne
- 3.2k
- Forks
- 227
- Ø Merge
- 16 Min.
- Gemergte PRs (30 T.)
- 1
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus callstack/react-native-builder-bob
-
Doesn't work with NPMOffenbug
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 45/100
-
bug
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 42/100
callstack/react-native-builder-bob#896 · 2 Kommentare ·
-
bug
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 25/100
-
bug
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 42/100
callstack/react-native-builder-bob#852 · 1 Kommentar · 1 Reaktion ·
-
bug
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 35/100
callstack/react-native-builder-bob#829 · 20 Kommentare ·
Alle Issues in callstack/react-native-builder-bob
Ähnliche Issues
-
accepting PR Content:HTML
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 88/100
mdn/content#45988 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
pnpm/pnpm#16635 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
paperclipai/paperclip#15253 ·
Maintainer antworten meist innerhalb von 1 Tag
-
needs triage
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
solana-foundation/solana-com#2245 ·
Maintainer antworten meist innerhalb von 1 Tag