Conversation
tsdown.config.ts
Outdated
| treeshake: true, | ||
| outDir: 'dist', | ||
| dts: true, | ||
| inlineOnly: false, |
There was a problem hiding this comment.
Not sure if it's better to make 'hash-wasm' external or bundle it
There was a problem hiding this comment.
what is the difference between them? (pros vs cons)
There was a problem hiding this comment.
As I get it: one is clean, and has no external dependencies (current one), another is (with hash-wasm made external) will require any library that uses internxt-crypto to install hash-wasm as a dependency. In theory the second way can prevent double loading and be easier if different builders are used. But not sure
There was a problem hiding this comment.
I will left it bundled in order to avoid future incompatible issues in different hash-wasm versions (as we have in crypto-js in another projects with 4.2 and <4.2.
Also I think better to change inlineOnly, InlineOnly: false silences the warning, if another dep is bundled in the future, there will be nothing to detect it.
A more robust alternative would be: inlineOnly: [“hash-wasm”]
This also removes the warning, but also acts as a whitelist, if any other node_modules package is accidentally bundled, tsdown will throw an error in the build
There was a problem hiding this comment.
i see, lets let it bundle and we'll see
|



Description
Fix npm warning to enable release
Checklist
Testing Process
unit tests