Skip to content

Commit ea12229

Browse files
committed
refactor(firestore/pipelines): drop RN-only Type export
1 parent 7cad3ca commit ea12229

7 files changed

Lines changed: 5 additions & 49 deletions

File tree

.github/scripts/compare-types/configs/firestore-pipelines.ts

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,7 @@ import type { PackageConfig } from '../src/types';
2222
const config: PackageConfig = {
2323
nameMapping: {},
2424
missingInRN: [],
25-
extraInRN: [
26-
{
27-
name: 'Type',
28-
reason:
29-
'RN Firebase exposes a local type discriminator alias for pipeline expression helpers.',
30-
},
31-
],
25+
extraInRN: [],
3226
differentShape: [],
3327
};
3428

docs/firestore/pipelines/sdk-compatibility.mdx

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ CI enforces parity through `yarn compare:types` and the `firestore-pipelines` al
1616
| Core pipeline builder (`pipeline()`, stages, `execute()`) | **Supported** on Android, iOS, and macOS |
1717
| Expression helpers (aggregates, strings, arrays, maps, timestamps, vectors) | **Mostly supported** — see gaps below |
1818
| Newer firebase-js-sdk helpers (2025–2026) | **Partial** — tracked in "Not yet available" |
19-
| firebase-js-sdk `Type` export | **React Native Firebase only** — use `isType()` with our `Type` union |
2019

2120
# Not yet available in React Native Firebase
2221

@@ -35,16 +34,10 @@ These exports exist in both SDKs but differ in typing or optional parameters:
3534
| Export | Difference |
3635
| ----------------- | --------------------------------------------------------------------- |
3736
| `timestampDiff` | Declaration overload ordering differs; all four SDK shapes supported |
38-
| `isType` | RNFB accepts the local `Type` alias; JS SDK accepts a broader string |
37+
| `isType` | Accepts the type name as a `string`, matching the JS SDK |
3938
| `StageOptions` | Equivalent runtime shape; declaration formatting differs |
4039
| `TimeGranularity` | RNFB uses `isoWeek` / `isoYear`; JS SDK also lists lowercase variants |
4140

42-
# React Native Firebase only
43-
44-
| Export | Notes |
45-
| ------ | ----------------------------------------------------------------------- |
46-
| `Type` | Local type discriminator union used with `isType()` and related helpers |
47-
4841
# Platform execution matrix
4942

5043
| Platform | Execution backend | Pipeline database |

okf-bundle/testing/compare-types-work-queue.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ Before any item's `implementation`:
8484
| **A10** | cross-cutting | `fix(types): align compare-types modular API with firebase-js-sdk` | closed | closed | closed || `area-focused` | Review green — app structural + callbacks |
8585
| **B0** | Phase B scope | `refactor!(types): align modular APIs with firebase-js-sdk sync signatures` | closed | closed | closed || `none` | Gap-analysis + grilling decisions 2026-07-03 — see [Phase B Notes](#phase-b-notes) |
8686
| **B1** | firestore-pipelines | `refactor(firestore/pipelines): add constant preferIntegers option` | closed | closed | closed || `area-focused` | Re-review green 2026-07-04: parser integerLiteral iOS/Android, preferIntegers e2e, sdk-compat; macOS 147 / iOS 152 / Android 152 |
87-
| **B2** | firestore-pipelines | `feat(firestore/pipelines): expose search stage and pipeline expressions` | closed | closed | closed || `area-focused` |`missingInRN` cleared; macOS 150/150; iOS/Android 155/155; firebase-tools 15.22.4; search index verify cycle |
87+
| **B2** | firestore-pipelines | `feat(firestore/pipelines): expose search stage and pipeline expressions` | closed | closed | closed || `area-focused` |`missingInRN` cleared; macOS 150/150; iOS/Android 155/155; firebase-tools 15.22.4; search index verify cycle. Follow-up: dropped RN-only `Type` export → pipelines 0 documented diffs |
8888
| **B3** | storage || open | open | open || `area-focused` | **Blocked** — Phase S native sync |
8989
| **B4** | analytics | `refactor!(types): align modular APIs with firebase-js-sdk sync signatures` | closed | closed | closed || `unit-focused` | logEvent sync void |
9090
| **B5** | app-check | `refactor!(types): align modular APIs with firebase-js-sdk sync signatures` | closed | closed | closed || `area-focused` | initializeAppCheck sync AppCheck |

packages/firestore/consumer-type-test.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,6 @@ import type {
258258
FunctionExpression,
259259
AggregateFunction,
260260
ExpressionType,
261-
Type as PipelineValueType,
262261
TimeGranularity,
263262
TimePart,
264263
TimeUnit,
@@ -902,7 +901,6 @@ type _AllPipelineTypes = [
902901
FunctionExpression,
903902
AggregateFunction,
904903
ExpressionType,
905-
PipelineValueType,
906904
TimeGranularity,
907905
TimePart,
908906
TimeUnit,
@@ -1009,7 +1007,7 @@ void isAbsent(field('optionalField'));
10091007
void isAbsent('optionalField');
10101008
// isError
10111009
void isError(field('computedField'));
1012-
// isType: (string, Type) | (Expression, Type)
1010+
// isType: (string, string) | (Expression, string)
10131011
void isType(field('value'), 'string');
10141012
void isType('value', 'number');
10151013
// ifAbsent: (Expression, Expression) | (Expression, unknown) | (string, Expression)

packages/firestore/lib/pipelines/expressions.ts

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -34,32 +34,6 @@ export type ExpressionType =
3434
| 'Variable'
3535
| 'PipelineValue';
3636

37-
/**
38-
* @beta
39-
* Firestore value type for isType() checks.
40-
*/
41-
export type Type =
42-
| 'null'
43-
| 'array'
44-
| 'boolean'
45-
| 'bytes'
46-
| 'timestamp'
47-
| 'geo_point'
48-
| 'number'
49-
| 'int32'
50-
| 'int64'
51-
| 'float64'
52-
| 'decimal128'
53-
| 'map'
54-
| 'reference'
55-
| 'string'
56-
| 'vector'
57-
| 'max_key'
58-
| 'min_key'
59-
| 'object_id'
60-
| 'regex'
61-
| 'request_timestamp';
62-
6337
/**
6438
* @beta
6539
* Time unit for timestamp arithmetic expressions.

packages/firestore/lib/pipelines/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ export type {
3535
FunctionExpression,
3636
AggregateFunction,
3737
ExpressionType,
38-
Type,
3938
TimeGranularity,
4039
TimePart,
4140
TimeUnit,

packages/firestore/type-test.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,6 @@ import type {
244244
FunctionExpression,
245245
AggregateFunction,
246246
ExpressionType,
247-
Type as PipelineValueType,
248247
TimeGranularity,
249248
TimePart,
250249
TimeUnit,
@@ -874,7 +873,6 @@ type _AllPipelineTypes = [
874873
FunctionExpression,
875874
AggregateFunction,
876875
ExpressionType,
877-
PipelineValueType,
878876
TimeGranularity,
879877
TimePart,
880878
TimeUnit,
@@ -980,7 +978,7 @@ void isAbsent(field('optionalField'));
980978
void isAbsent('optionalField');
981979
// isError
982980
void isError(field('computedField'));
983-
// isType: (string, Type) | (Expression, Type)
981+
// isType: (string, string) | (Expression, string)
984982
void isType(field('value'), 'string');
985983
void isType('value', 'number');
986984
// ifAbsent: (Expression, Expression) | (Expression, unknown) | (string, Expression)

0 commit comments

Comments
 (0)