krisk / Fuse

Lightweight fuzzy-search, in JavaScript
https://fusejs.io/
Apache License 2.0
18.2k stars 768 forks source link

Unexpected token '...'. Expected a property name #445

Closed WilliamALiang closed 4 years ago

WilliamALiang commented 4 years ago

Describe the bug

A clear and concise description of what the bug is. Unexpected token '...'. Expected a property name ### Version The Fuse.js version where this bug is happening. fuse.js@6.0.4 ios 10.3.1 ### Is this a regression? Yes, the previous version in which this bug was not present was: ... ### 🔬Minimal Reproduction

Additional context

krisk commented 4 years ago

Using this in IE?

jmheldsans commented 4 years ago

Not sure about OP, but I am attempting to use it in IE11. The arrow function in fuse.esm.js prevents this. Is there a different way I should be using Fuse?

WilliamALiang commented 4 years ago

@krisk Using this in android 5.1-7.1 and ios 10.3.1 Must be brought in manually /dist/fuse.min.js

daphnesmit commented 2 years ago

Types for fuse min:

declare module 'fuse.js/dist/fuse.min.js' {
  import Fuse from 'fuse.js';
  export default Fuse;
}
daphnesmit commented 2 years ago

I used the dist version in a package i have, but when i install that package in nextjs and build it it is still showing object spread stuff