omit
Omit the specified fields from an item.
ts
import { omit } from 'feathers-utils/transformers';Type declaration
ts
/**
* Omit the specified fields from an item.
*
* @example
* ```ts
*
*
*
* {
* before: {
* all: [transformData(omit('email'))],
* }
* }
* ```
*/
export declare const omit: (fieldNames: MaybeArray<string>) => TransformerFn| Argument | Type | Description |
|---|---|---|
| fieldNames | MaybeArray<string> |
Example
ts
import { transformData, transformResult } from 'feathers-utils/hooks'
import { omit } from 'feathers-utils/transformers'
{
before: {
all: [transformData(omit('email'))],
}
}