Skip to content

Added NPM and PNPM installation in README.md#1149

Open
I-am-Pritam-20 wants to merge 3 commits into
software-mansion:mainfrom
I-am-Pritam-20:patch-2
Open

Added NPM and PNPM installation in README.md#1149
I-am-Pritam-20 wants to merge 3 commits into
software-mansion:mainfrom
I-am-Pritam-20:patch-2

Conversation

@I-am-Pritam-20
Copy link
Copy Markdown
Contributor

Description

Added NPM and PNPM installation in README.md with details+ summary tag. Atleast new developers won't get scared if they are using npm and suddenly need yarn

Introduces a breaking change?

  • Yes
  • No

Type of change

  • Bug fix (change which fixes an issue)
  • New feature (change which adds functionality)
  • Documentation update (improves or adds clarity to existing documentation)
  • Other (chores, tests, code style improvements etc.)

Tested on

  • iOS
  • Android

Testing instructions

Screenshots

Related issues

Checklist

  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have updated the documentation accordingly
  • My changes generate no new warnings

Additional notes

Copy link
Copy Markdown
Contributor Author

@I-am-Pritam-20 I-am-Pritam-20 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check for the commands exist or not
npm < ios | android >
pnpm < ios | android >

Comment thread README.md Outdated
Comment on lines +100 to +138
<br>
<details>
<summary><strong>Check for NPM Installation</strong></summary>

```bash
npm install react-native-executorch

# For Expo projects, you need to install expo resource fetcher
npm install react-native-executorch-expo-resource-fetcher
npm install expo-file-system expo-asset

# For bare React Native projects, you need to install bare resource fetcher
npm install react-native-executorch-bare-resource-fetcher
npm install @dr.pogodin/react-native-fs @kesha-antonov/react-native-background-downloader

# Depending on the platform, choose either iOS or Android
npm < ios | android >
```
</details>
<br>
<details>
<summary><strong>Check for PNPM Installation</strong></summary>

```bash
pnpm install react-native-executorch

# For Expo projects, you need to install expo resource fetcher
pnpm install react-native-executorch-expo-resource-fetcher
pnpm install expo-file-system expo-asset

# For bare React Native projects, you need to install bare resource fetcher
pnpm install react-native-executorch-bare-resource-fetcher
pnpm install @dr.pogodin/react-native-fs @kesha-antonov/react-native-background-downloader

# Depending on the platform, choose either iOS or Android
pnpm < ios | android >
```
</details>
<br>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think these new lines are needed here. Could you remove these manual <br>s?

@msluszniak
Copy link
Copy Markdown
Member

Check for the commands exist or not npm < ios | android > pnpm < ios | android >

There is no such command as npm <ios | android> I'm afraid.

@msluszniak msluszniak added the documentation Improvements or additions to documentation label May 13, 2026
@I-am-Pritam-20
Copy link
Copy Markdown
Contributor Author

I-am-Pritam-20 commented May 13, 2026

Then devloper must have yarn installed in the system 😂.

Then publishing package to npm or pnpm doesn't make any sense 😂.

Is this package created with react-native-builder-blob ? Then in that case yarn needed, but I think npm and pnpm build commands can still be configured.

@msluszniak
Copy link
Copy Markdown
Member

msluszniak commented May 13, 2026

Then devloper must have yarn installed in the system 😂.

Then publishing package to npm or pnpm doesn't make any sense 😂.

No, developer doesn't need to use yarn. Correct commands are npm run <ios | android > (since npm does not support script expansion) and pnpm <ios | android> respecitively. But I will be very honest with you. This change will probably not land on the main since adding separate instructions for each and every package manager doesn't give much information for a user, and README.md must be kept to the point.

@I-am-Pritam-20
Copy link
Copy Markdown
Contributor Author

I-am-Pritam-20 commented May 13, 2026

This is required so that if a new developer (as a user only of this package) having npm or pnpm installed in the system and directly go through the github README , then he/she should atleast get to know that this package can be used completely with npm or pnpm too.

Because still a doc is a doc. And should clarify the minimal doubts.

This is just my perspective.🙂

You can add this or close this, as you and your team wish 🫡.

And also if npm build scripts will be configured then during the build time the developer's machine will get the compiled codes(already compiled with type safety) and performance may increase, lesser load on CPU + memory.

@msluszniak
Copy link
Copy Markdown
Member

And also if npm build scripts will be configured then during the build time the developer's machine will get the compiled codes(already compiled with type safety) and performance may increase, lesser load on CPU + memory.

The package is shipped pre-built to the npm registry; all three package managers fetch the same compiled artifact, so install-time CPU/memory and runtime performance are unaffected by the choice.

At this moment I can agree on one liner instead of three separate blocks: npm/pnpm work too — use `npm install` or `pnpm add` for packages, and `npm run <ios|android>` / `pnpm <ios|android>` for the run step.. I will consult this with the rest of the team and with get back to you. Would this be ok?

@I-am-Pritam-20
Copy link
Copy Markdown
Contributor Author

"Would this be ok" . Hah I am not very used to with this line 😂.
You guys and your team are maintaining the things I am just suggesting , so do as you want 🙂.

And it will be okay if you are not getting back to me. 😂

Btw appreciated the conversation 🫡.

I know you guys will definitely find some solution for that.

- README: replace accordion blocks with a one-line note that npm/pnpm
  work too; mirror the note in es/fr/cn/pt/in translations
- docs/getting-started: split the bulky combined install block into
  separate steps (core package, then Expo or bare resource fetcher),
  with small per-package-manager tabs in each step
- docs/loading-models: add npm/pnpm tabs alongside the yarn commands

Co-Authored-By: Pritam <pritamnanda504@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants