run npm i gachchan
- nanoid
Peers
- lodash
- decimal.js
https://github.com/sponsors/lockevn
- change
package.json
version string - (Optional) run in local those commands
pnpm run ci
andpnpm release
to build the output package (to test) - Create git tag and publish the git tag
This lib gachchan
use _intersection from 'lodash/intersection'
to import function from lodash
-
_intersection
will not be bundled intogachchan
by default. When you writeimport \_intersection from 'lodash/intersection'
, it creates a dependency that expectslodash
to be available at runtime. -
Specify
"peerDependencies": { "lodash": "^4.17.21" }
ingachchan
.You're using
lodash
but want to allow the consuming project to control thelodash
version It prevents multiple copies oflodash
in the final application It makes it clear to users ofgachchan
that they need to installlodash
-
Do
tts-wallet
(which usegachchan
) need to depend onlodash
?- Yes,
tts-wallet
needs to installlodash
as a direct dependency because: - It's a peer dependency of
gachchan
The import statements ingachchan
expect to findlodash
innode_modules
- If
tts-wallet
doesn't installlodash
, you'll get runtime errors about missing modules
- Yes,
- Parcel to build https://dev.to/ihaback/create-your-own-typescript-library-with-parceljs-3dh7
- Package manager pnpm
- Release with semantic-release
- Test with https://vitest.dev