Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Package-json.md - Updated example for monorepo and json to jsonc #6656

Open
wants to merge 3 commits into
base: latest
Choose a base branch
from

Conversation

hychan48
Copy link

@hychan48 hychan48 commented Jul 19, 2023

Added folder tree to visualize example.

  1. Added folder tree to help visualize the package.json Monorepo react example.
  2. json to jsonc (json blocks with comments)

References

json to jsonc. for sections with comments.
Minor change for github markdown to stop showing
Updated example for monorepo, react, react-dom
Also, added tree folder structure
@hychan48 hychan48 requested a review from a team as a code owner July 19, 2023 03:41
```json
If your `package.json` isn't in the root directory, common with monorepos like Facebook's React, you can specify its location. i.e. `react-dom`:
```jsonc
/* @/packages/react-dom/package.json */
Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure this is a helpful comment, is it just a bare comment of a path with some sort of "shorthand" for @ meaning cwd?

Copy link
Author

Choose a reason for hiding this comment

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

I'm not sure this is a helpful comment, is it just a bare comment of a path with some sort of "shorthand" for @ meaning cwd?

Yea. I couldn't think of a good shorthand. This felt too long:
https://github.com/facebook/react/blob/main/packages/react-dom/package.json

I wanted to be verbose on which package.json the block was referring to

@hychan48 hychan48 requested a review from wraithgar July 22, 2023 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants