Issue: Improve `bootstrap.js` to support both Yarn and NPM with clearer errors
评估
这个 Issue 还没有评估数据。
描述
Feature request for Cloudinary React Native SDK
Improve scripts/bootstrap.js to support both Yarn and NPM with clearer error handling.
Explain your use case
When contributing to this repository, new developers typically start with npm install.
However, the current scripts/bootstrap.js assumes Yarn is installed.
If Yarn is missing, the script fails without guidance, making onboarding harder for contributors who default to npm.
Describe the problem you’re trying to solve
Right now:
- The script hardcodes Yarn and fails if it’s not installed.
- There is no fallback to
npm run bootstrap. - If
bootstrapis not defined inpackage.json, the script exits with no explanation.
This creates friction for new contributors and may result in unnecessary issues being opened.
Do you have a proposed solution?
Yes.
- Detect if Yarn is available; if not, fall back to
npm run bootstrap. - Allow contributors to explicitly prefer npm (e.g. with a flag like
--use-npm). - Validate that a
bootstrapscript exists inpackage.jsonbefore trying to run it. - Print clear, contributor-friendly error messages when something fails.
This change would not alter the default behavior for Yarn users, but it would improve reliability, reduce confusion, and make onboarding easier for developers using npm.
- 主要语言
- TypeScript
- 星标
- 28
- 派生
- 21
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
cloudinary/cloudinary-react-native 的其他 Issue
-
hacktoberfest-accepted
难度 3/5 1-2 天 新手友好度 45/100
cloudinary/cloudinary-react-native#55 · 3 条评论 ·
-
Add CODE_OF_CONDUCT.md可能重新可做 @adimiz1 于 405 天前认领,目前没有进行中的 PR。 未关闭
cloudinary/cloudinary-react-native#53 · 2 条评论 · 已指派 1 人 ·
-
难度 2/5 1-3 小时 新手友好度 45/100
cloudinary/cloudinary-react-native#52 · 8 条评论 ·
-
难度 5/5 一周以上 新手友好度 15/100
-
难度 5/5 一周以上 新手友好度 25/100
cloudinary/cloudinary-react-native#31 · 3 条评论 ·
查看 cloudinary/cloudinary-react-native 的全部 Issue
相似的 Issue
-
area:docs documentation good first issue
难度 2/5 1-3 小时 新手友好度 85/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 12 天内回复
-
area:docs good first issue
难度 2/5 1-3 小时 新手友好度 62/100
thainanluiz/TSSuper#30 ·
-
[analytics-core] getQueryParams does not decode `+` as space and truncates values containing `=`未关闭bug
难度 2/5 1-3 小时 新手友好度 82/100
amplitude/Amplitude-TypeScript#2179 · 1 条评论 ·
维护者通常 2 天内回复
-
ci good first issue severity: low
难度 2/5 1-3 小时 新手友好度 68/100
TMHSDigital/GH-Arcade#111 ·