feat(index): Provide a similar API to Query (#9193)
**What**
Align the index engine API to be similar to the Query API
## Example
```ts
// Benefit from the same level of typing like the remote query
const { data, metadata } = await indexEngine.query<'product'>({
fields: [
"product.*",
"product.variants.*",
"product.variants.prices.*",
],
filters: {
product: {
variants: {
prices: {
amount: { $gt: 50 },
},
},
},
},
pagination: {
order: {
product: {
variants: {
prices: {
amount: "DESC",
},
},
},
},
},
})
```
This commit is contained in:
@@ -323,6 +323,7 @@ export const ModulesDefinition: {
|
||||
Modules.EVENT_BUS,
|
||||
"logger",
|
||||
ContainerRegistrationKeys.REMOTE_QUERY,
|
||||
ContainerRegistrationKeys.QUERY,
|
||||
],
|
||||
defaultModuleDeclaration: {
|
||||
scope: MODULE_SCOPE.INTERNAL,
|
||||
|
||||
Reference in New Issue
Block a user