Skip to Content
Mesh

Prune Transform

The prune transform allows you removing unused and empty types.

How to use?

mesh-config.ts
import { createPruneTransform, defineConfig, loadGraphQLHTTPSubgraph } from '@graphql-mesh/compose-cli' export const composeConfig = defineConfig({ subgraphs: [ { sourceHandler: loadGraphQLHTTPSubgraph('Users', { endpoint: 'http://localhost:4001/users' }), transforms: [ createPruneTransform({ // Skip pruning for specific types skipPruning: ['MyPrecioiusType'] }) ] } ] })
Last updated on