casper-ecosystem / casper-js-sdk

TypeScript Casper Client SDK
Apache License 2.0
71 stars 60 forks source link

fix: rename lib.js to lib.web.js #387

Closed akwodkiewicz closed 5 months ago

akwodkiewicz commented 5 months ago

This fixes TypeScript support for NodeNext/Node16/Bundler moduleResolution.

The issue was that the ./dist/lib.js has a higher precedence than ./dist/lib/index.d.ts when TypeScript tries to resolve "./lib" imports/exports.

Instead of renaming the whole lib/ folder I decided to add a infix to the lib.js artifact. But to solve the issue you could've renamed the directory instead.

Resolves #386

hoffmannjan commented 5 months ago

Will be included in 2.15.4.