Closed dmurawsky closed 3 years ago
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days
@krisk is this a known issue. I'm a patreon supporter if that helps :)
Hey! Would you have a sample project I can check? Have you tried just doing import Fuse from 'fuse.js'
? Could you also share your tsconfig.json
? Thanks!
Thanks Krisk, I created a basic TS CRA example and it seems to be working fine. It's failing in a Ruby on Rails project that uses the webpacker ruby gem so that's probably the issue. We're moving this project out of webpacker pretty soon so we're not worried about it.
I also encouter this problem like below, after I use CRA build my react rpoject, but I don't use typescript. How could I solve this problem ? Thx.
Describe the bug
./node_modules/fuse.js/dist/fuse.esm.js
Module parse failed: Unexpected token (271:2)
You may need an appropriate loader to handle this file type.
|
| var Config = {
| ...BasicOptions,
| ...MatchOptions,
| ...FuzzyOptions,
Version
6.4.3
Describe the bug
TypeScript can't import the library
Version
6.4.3
Is this a regression?
No
🔬Minimal Reproduction
Import Fuse into a TypeScript app