# dispose()

Cleans up a route handler module.

:::note
[Route handler **modules**](/docs/platform/lwr/guide/lwr-route-handler-modules.md), which are used in client-side routing, aren’t the same as [route handler **functions**](/docs/platform/lwr/guide/lwr-routing-server.md#route-handler-functions), which are used in server-side routing.
:::

## Properties

None

## Syntax

```javascript
dispose(): void {
        // perform cleanup tasks
    }
```

## Signature

```javascript
public void dispose()
```

## Returns

- None

**See Also**

- [Route Handler Modules](/docs/platform/lwr/guide/lwr-route-handler-modules.md#dispose)
- [Simple Routing Example: Create a Route Handler](/docs/platform/lwr/guide/lwr-routing-example-simple.md#create-a-route-handler)
