@velocitycareerlabs/template-package
v1.21.0-dev-build.15d7e70f3
Published
Example package for monorepo packages, to be copied as a starting point
Downloads
1,741
Readme
Introduction
The package contains the minimum starting point, of what defines a package for us.
New Package Creation Instructions
Steps
This directory should be copied and renamed to the package name. The
"name"
field in thepackage.json
should be updated to match the directory name, prefixed by@velocitycareerlabs
as seen by thetemplate-package
name:"@velocitycareerlabs/template-package"
A description should be added in the
"description"
field in thepackage.json
This
README.md
should be cleared and used for relevant information in the new package.
Some points to take note of:
"repository"
field inpackage.json
is important and is used later when we setup scopes withlerna
They packages actually get published, but we don't consume the packages directly from their publish location, instead we rely on
lerna
cli within the repository like so:lerna add [CONSUMED-PACKAGE-NAME] --scope [CONSUMING-PACKAGE-NAME]
So if you want
did-docs
package to use thecrypto
package, you would do:lerna add @velocitycareerlabs/crypto --scope @velocitycareerlabs/did-docs
Packages uses standard structure, of
src
directory, and thentest
directory for corresponding testsTests can be run from
package.json
scriptTests will be automatically included in global test suite and run in CI