> For the complete documentation index, see [llms.txt](https://frinn.gitbook.io/custom-machinery-1.21/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://frinn.gitbook.io/custom-machinery-1.21/mod-integrations/kubejs/recipes/dimension.md).

# Dimension

Use the dimension requirement in a KubeJS recipe

#### **Use one of these methods to add a** [Dimension **Requirement**](/custom-machinery-1.21/recipes/requirements/dimension.md) **to the recipe.**

```javascript
.dimensionWhitelist(String dimension)
.dimensionWhitelist(String[] dimensions)

.dimensionBlacklist(String dimension)
.dimensionBlacklist(String[] dimensions)
```

* The `dimension` param must be a string defining a valid dimension id. \
  Example : `minecraft:overworld`

### Example

```javascript
ServerEvents.recipes(event => {

  event.recipes.custommachinery.custom_machine("custommachinery:power_crusher", 100)
  .dimensionWhitelist("minecraft:overworld")
  
})
```
