Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FuseIndex type isn't exported in Fuse namespace #519

Closed
yunyu opened this issue Dec 6, 2020 · 1 comment · May be fixed by usernamerandom11/JokeAPI#38 or usernamerandom11/JokeAPI#39
Closed

FuseIndex type isn't exported in Fuse namespace #519

yunyu opened this issue Dec 6, 2020 · 1 comment · May be fixed by usernamerandom11/JokeAPI#38 or usernamerandom11/JokeAPI#39
Labels

Comments

@yunyu
Copy link

yunyu commented Dec 6, 2020

Describe the bug

The type for FuseIndex isn't exported in the Fuse namespace

Version

6.4.1

Is this a regression?

No

🔬Minimal Reproduction

import { FuseIndex } from "fuse.js"

Additional context

This makes it impossible to type the result of Fuse.createIndex without actually calling the method (say, storing the value in a map or loading from disk).

A non-obvious workaround is to do:

ReturnType<Fuse<GenericArgument>["getIndex"]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment