andreasbm / weightless

High-quality web components with a small footprint
MIT License
377 stars 31 forks source link

Cannot resolve dependency 'tslib' #83

Open dy opened 5 years ago

dy commented 5 years ago

Just installed weightless, getting that error:

C:\projects\wishbox\node_modules\weightless\behavior\overlay\overlay-behavior.js:10:39: Cannot resolve dependency 'tslib'
jsantell commented 4 years ago

I've ran into this as well when using snowpack.dev -- tslib is listed as a devDependency, so it's not installed when installing weightless as a dependency. Adding tslib to my own devDependencies and building works, although tslib should either be set as dependency in weightless in that case. Since only utility functions __decorate and __metadata are used from tslib, it might be preferable to just self host those rather than have all of tslib as a dep.