---
editLink: false
lastUpdated: false
---

[@salesforce/b2c-tooling-sdk](../../../modules.md) / [operations/mrt](../index.md) / createGlobFilter

# Function: createGlobFilter()

> **createGlobFilter**(`patterns?`): (`path`) => `boolean`

Defined in: [packages/b2c-tooling-sdk/src/operations/mrt/bundle.ts:140](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/67fb8580ac3c5b372617ee3ec3fc8f2bc9f16174/packages/b2c-tooling-sdk/src/operations/mrt/bundle.ts#L140)

Creates a glob filter function from patterns.

Patterns can include negations (prefixed with !).
A path matches if it matches any positive pattern
and does not match any negative pattern.

## Parameters

### patterns?

`string`[]

Glob patterns to match against

## Returns

Filter function that returns true for matching paths

> (`path`): `boolean`

### Parameters

#### path

`string`

### Returns

`boolean`
