diff --git a/package.json b/package.json index 89b815e..53cc622 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "firelordjs", - "version": "2.8.6", + "version": "2.8.7", "description": "🔥 High Precision Typescript Wrapper for Firestore Web, Providing Unparalleled Type Safe and Dev Experience", "author": "tylim", "license": "MIT", diff --git a/src/abc.ts b/src/abc.ts deleted file mode 100644 index 33274dc..0000000 --- a/src/abc.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - getFirelord, - MetaTypeCreator, - getFirestore, - query, - orderBy, - where, -} from './index' - -type A = MetaTypeCreator<{ a: number; b: string }, 'A'> - -const a = getFirelord(getFirestore(), 'A') - -const q1 = query(a.collection(), where('a', '==', 1), orderBy('b')) - -const q2 = query(a.collection(), orderBy('b'), where('a', '==', 1)) diff --git a/src/tests/discriminatedUnion.test.ts b/src/tests/discriminatedUnion.test.ts index 0c7867a..c5a0d57 100644 --- a/src/tests/discriminatedUnion.test.ts +++ b/src/tests/discriminatedUnion.test.ts @@ -78,13 +78,18 @@ describe('test discrimination unions', () => { // @ts-expect-error updateDoc(docRef, data) - updateDoc(docRef, { random: { k: { '1': 1, '2': 2 } } }) + updateDoc(docRef, { x: { k: { '1': 1, '2': 2 } } }) const a = { m: '1' as '1' | '2' | '3' } const b = a.m - updateDoc(docRef, { random: { k: { [b]: 1 } } }) + const c = { + x: { k: { [b]: 1 as const } as const } as const, + } as const + // ! should not error but this seem like TS fault + // @ts-expect-error + updateDoc(docRef, c) } })