> For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt, and this page is available as Markdown at /api/rspeedy/rspeedy.config.environments.md.

# 

<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](/api/rspeedy/index.md) > [@lynx-js/rspeedy](/api/rspeedy/rspeedy.md) > [Config](/api/rspeedy/rspeedy.config.md) > [environments](/api/rspeedy/rspeedy.config.environments.md)

## Config.environments property

The [Config.environments](/api/rspeedy/rspeedy.config.environments.md) option is used to set the output environment.

**Signature:**

```typescript
environments?: RsbuildConfig['environments'] | undefined;
```

## Default Value

When this option is unset, Rspeedy passes `{ lynx: {} }` to Rsbuild.

## Remarks

Normally you don't need this if you are not using Lynx for Web.

## Example 1

- Using different entries for Lynx and Web.

```ts
import { defineConfig } from '@lynx-js/rspeedy'

export default defineConfig({
  environments: {
    lynx: {},
    web: {
      source: { entry: { web: './src/index.web.jsx' } },
    },
  },
  source: {
    entry: './src/index.jsx',
  },
})
```

## Example 2

- Building Web-only outputs.

```ts
import { defineConfig } from '@lynx-js/rspeedy'

export default defineConfig({
  environments: {
    web: {
      source: { entry: { web: './src/index.web.jsx' } },
    },
  },
})
```
