Conversation
🦋 Changeset detectedLatest commit: 4ef1098 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
Code Review
This pull request introduces subquery support to Firestore Pipelines, adding new expressions such as arrayFilter, arraySlice, and arrayTransform, along with subcollection and define stages. It also enables converting pipelines into expressions via toArrayExpression and toScalarExpression. Feedback identifies several areas for improvement, including restoring missing documentation for the timestampDiff function, removing a .only modifier from tests, fixing documentation formatting and typos, and ensuring naming consistency for internal method identifiers.
| // Warning: (ae-incompatible-release-tags) The symbol "timestampDiff" is marked as @public, but its signature references "Expression" which is marked as @beta | ||
| // Warning: (ae-incompatible-release-tags) The symbol "timestampDiff" is marked as @public, but its signature references "FunctionExpression" which is marked as @beta | ||
| // | ||
| // @public (undocumented) |
There was a problem hiding this comment.
The timestampDiff function has been promoted to @public but is marked as (undocumented). This has resulted in its documentation being removed from the generated doc files (e.g., docs-devsite/firestore_lite_pipelines.md). Public APIs must have complete TSDoc documentation. Please add the documentation for this function.
| expectResults(snapshot, ...expectedResults); | ||
| }); | ||
|
|
||
| it.only('supports arrayFilter', async () => { |
| ## Expression.arrayFilter() | ||
|
|
||
| > This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment. | ||
| > |
| return new FunctionExpression( | ||
| 'get_field', | ||
| [this, valueToDefaultExpr(key)], | ||
| 'get_field' |
| * <p>Result Unwrapping:</p> | ||
| * <ul> | ||
| * <li>If the item has a single field, its value is unwrapped and returned directly.</li> | ||
| * <li>f the item has multiple fields, they are returned as an object.</li> |
Add
arraySlice,arrayFilter,arrayTransformandarrayTransformWithIndexexpressions