mirror of
https://github.com/krisk/Fuse.git
synced 2026-01-25 16:43:11 +00:00
Added list property in typings (#348)
This commit is contained in:
parent
2efc7b3242
commit
be759d5c08
1
src/typings.d.ts
vendored
1
src/typings.d.ts
vendored
@ -28,6 +28,7 @@ declare class Fuse<T, O extends Fuse.FuseOptions<T>> {
|
||||
)
|
||||
|
||||
setCollection(list: ReadonlyArray<T>): ReadonlyArray<T>;
|
||||
list: ReadonlyArray<T>
|
||||
}
|
||||
|
||||
declare namespace Fuse {
|
||||
|
||||
@ -42,6 +42,10 @@ describe('Flat list of strings: ["Apple", "Orange", "Banana"]', () => {
|
||||
expect(fuse).toMatchObject(expected)
|
||||
})
|
||||
|
||||
it('should have the list property', () => {
|
||||
expect(fuse.list).toBe(defaultList)
|
||||
})
|
||||
|
||||
describe('When searching for the term "Apple"', () => {
|
||||
let result
|
||||
beforeEach(() => result = fuse.search('Apple'))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user