Skip to content

Commit

Permalink
docs: update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Natoandro committed Feb 15, 2024
1 parent 85f68d8 commit 8211dc2
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
8 changes: 8 additions & 0 deletions website/docs/reference/types/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,14 @@ created with the [runtime](./runtimes) instance.
|output type|any type|The type of the output data.|
|materializer|[`Materializer`](./runtimes)|The materializer to use to perform the operation/computation.|

#### Methods
|Method|Purpose|Reference page|
|---|---|---|
|`rate`|Rate limiting|[Rate limiting](/docs/reference/typegate/rate-limiting)|
|`reduce`|Parameter transformation|[`reduce`](/docs/reference/types/parameter-transformations#funcreducetree)|
|`apply`|Parameter transformation|[`apply`](/docs/reference/types/parameter-transformations#funcapplytree)|


#### Examples

```python
Expand Down
2 changes: 2 additions & 0 deletions website/docs/tutorials/metatype-basics/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -732,6 +732,8 @@ If you're using the GraphiQl interface from earlier, there should be a panel in

### `reduce`

**Reference**: [Parameter transformations](/docs/reference/types/parameter-transformations)

We can use the `reduce` method to modify the input types of functions.
This comes especially handy when dealing with generated functions like those from the CRUD helpers from the Prisma runtime.
By default, Prisma generates types that supports the whole suite of usecases one might have on a CRUD operation such as allowing creation of objects of related types in a single operation.
Expand Down

0 comments on commit 8211dc2

Please sign in to comment.