-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
doc: add new package #1013
doc: add new package #1013
Conversation
1c02e16
to
3bb5f8c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if applicable to the guide here, but should we include a list of all of the files (like index.js
, LICENSE
, etc.) that need to go into the package?
Also, a reminder to update the copyright headers of each file so that they reflect the package name and the current year should be helpful as well.
I personally think if this section was to exist, it should be detailed enough for anyone to be able to create a new lb4 package. It's outside of scope for your task though, so maybe this is good enough. I'm not sure.
3bb5f8c
to
d54b3dd
Compare
@shimks thanks! Good point I will add them:
It's not part of my task, just some notes, doesn't take big time to write. |
@jannyHou Good addition to the docs. I polished it to be the following. Add a new packageTo add a new package, create a folder in cd loopback-next/packages
mkdir <a-new-package> The package follows the node/npm module layout. You can use We have some configuration files at the top level (loopback-next/):
For consistency across all packages, do not add them at package level unless specific customization is needed. Please also register the new package in the following files:
By default, npm publishes scoped packages with private access. There are two options to make a new scoped package with public access. Add the following section to "publishConfig": {
"access": "public"
}, Explicitly publish the package with cd packages/<a-new-package>
npm publish --access=public |
091c868
to
44b209b
Compare
@raymondfeng thanks! Much better phrased than mine, I add your doc and @shimks 's suggestion in the new commit. |
Great stuff! I'd like to keep as much of developer docs in I am proposing the following steps:
|
44b209b
to
fa0d2b9
Compare
Thanks @bajtos ! I rebased my PR and will land it when CI green to unblock your patch. |
Description:
Add some guide on the things to remember when create a new package.
Any other stuff worth mentioning here?