Skip to content

Add missing READMEs & Update package.json in all RN packages#37090

Closed
Pranav-yadav wants to merge 1 commit into
react:mainfrom
Pranav-yadav:update-packageJsons
Closed

Add missing READMEs & Update package.json in all RN packages#37090
Pranav-yadav wants to merge 1 commit into
react:mainfrom
Pranav-yadav:update-packageJsons

Conversation

@Pranav-yadav

@Pranav-yadav Pranav-yadav commented Apr 25, 2023

Copy link
Copy Markdown
Contributor

Summary:

This diff adds missing README files for all public RN packages.

Changes:

For all public RN packages:

  • Add Missing READMEs

Update package.json in all RN packages to add:

  • Issues, Bugs urls
  • Keywords and Homepage urls to respective pkgs

Changelog:

[GENERAL][ADDED] - Add missing README files for all public RN packages.
[GENERAL][CHANGED] - Update package.json in all RN packages to add required fields.

Test Plan:

  • yarn lint && yarn flow && yarn test-ci --> should be green

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Apr 25, 2023
@analysis-bot

analysis-bot commented Apr 25, 2023

Copy link
Copy Markdown
Platform Engine Arch Size (bytes) Diff
android hermes arm64-v8a 8,499,710 +0
android hermes armeabi-v7a 7,833,554 +0
android hermes x86 8,977,657 +0
android hermes x86_64 8,834,477 +0
android jsc arm64-v8a 9,064,270 +0
android jsc armeabi-v7a 8,275,566 +0
android jsc x86 9,113,565 +0
android jsc x86_64 9,374,032 +0

Base commit: b0cf746
Branch: main

@Pranav-yadav

Pranav-yadav commented Apr 26, 2023

Copy link
Copy Markdown
Contributor Author

This PR is stacked on "Update Node.js to v16".

  • TODO: Rebase once that PR is merged. Rebased.

Note: I'll be unavailable due to uni. exams, if everything is okay, then please rebase (try slash rebase command) and merge or suggest and commit changes (edits allowed to maintainers) 👍

@cortinico cortinico requested a review from hoxyq April 27, 2023 10:59

@Pranav-yadav Pranav-yadav Apr 27, 2023

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Using symbols like ⚛️ in description is just extra noise for npm and other registries, that too at the start of the descriptions string.
Removing such symbols should make the search easier and should make the packages more accessible.

Same applies for all package.json files.

Comment thread packages/assets/package.json Outdated

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

git@ (old) & git:// (new) are more prone to attacks than https://.

Due to the lack of TLS or other cryptography, cloning over git:// might lead to an arbitrary code execution vulnerability, and should therefore be avoided unless you know what you are doing.

If you run git clone git://example.com/project.git, an attacker who controls e.g your router can modify the repo you just cloned, inserting malicious code into it. If you then compile/run the code you just cloned, you will execute the malicious code. Running git clone http://example.com/project.git should be avoided for the same reason.

Running git clone https://example.com/project.git does not suffer from the same problem (unless the attacker can provide a TLS certificate for example.com). Running git clone [git@example.com]:project.git only suffers from this problem if you accept a wrong ssh key fingerprint.

Reference: https://git-scm.com/book/en/v2/Git-on-the-Server-The-Protocols
It is very informative read 😃

@Pranav-yadav

Copy link
Copy Markdown
Contributor Author

Update: Had some free time, so rebased & resolved the conflicts 😅.

@hoxyq I've left self review above explaining why particular changes are done.
Also about adding more info to respective READMEs, I guess (contributors/maintainers) can iteratively do that as per convenience and shouldn't be a blocker for merging.

cc: @cortinico

@Pranav-yadav Pranav-yadav marked this pull request as ready for review April 27, 2023 17:04
Comment thread packages/assets/README.md Outdated
Comment thread packages/babel-plugin-codegen/README.md Outdated
Comment thread packages/eslint-plugin-specs/README.md Outdated
Comment thread packages/hermes-inspector-msggen/README.md Outdated
Comment thread packages/metro-config/README.md Outdated
Comment thread packages/normalize-color/README.md Outdated
Comment thread packages/polyfills/README.md Outdated
Comment thread packages/react-native/package.json Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@cortinico

Are we okay with these keywords?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

PS. I took them from keyword on RN gh repo page :)

Comment thread packages/virtualized-lists/README.md Outdated
Comment thread packages/assets/package.json Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What is the purpose of #readme suffix in all these links? Do we want to navigate to README file?

@Pranav-yadav Pranav-yadav Apr 27, 2023

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yup, that's the purpose of "homepage" field in case of packages under monorepo, unless we've specific page for each package on RN/any other website.
PS. If you look closely exact similar links are already used in RN packages.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Also, #... is just a "fragment" and won't break urls in any case.

@Pranav-yadav

Pranav-yadav commented Apr 27, 2023

Copy link
Copy Markdown
Contributor Author

Rebased & addressed suggestions re: jest testing syntax 👍

@Pranav-yadav Pranav-yadav requested a review from hoxyq April 27, 2023 20:37
For all public RN packages:
- Add missing READMEs
- Add issues, bugs urls
- Add keywords and homepage urls to respective pkgs
@facebook-github-bot

Copy link
Copy Markdown
Contributor

@hoxyq has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@facebook-github-bot facebook-github-bot added the Merged This PR has been merged. label Apr 28, 2023
@facebook-github-bot

Copy link
Copy Markdown
Contributor

@hoxyq merged this pull request in 14316bd.

@Pranav-yadav Pranav-yadav deleted the update-packageJsons branch April 28, 2023 12:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Merged This PR has been merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants