# Type alias WebpackCdnOptions

WebpackCdnOptions: {
enable?: boolean;
mapping?: boolean;
publicPath?: string;
}

Options for CDN server.

#### Type declaration

- ##### `Optional` enable?: boolean

  Enable the use of a CDN server for serving assets.

  - Setting this `true` will force `publicPath` default to `"auto"` for production mode unless mapping is also set to `true`.

- ##### `Optional` mapping?: boolean

  Enable URL mapping if CDN server gives a different URL for each asset

  - If `mapping` is `false`, then `publicPath` must be `"auto"` for assets to work.
  - If `mapping` is `true`, then post processing is required to provide the mapping data for the app.

- ##### `Optional` publicPath?: string

  If you don't need CDN mapping, but `"auto"` `publicPath` doesn't work, and you know ahead of time what it should be, then you can set it here.

- Defined in packages/xarc-app-dev/src/config/opt2/webpack-options.ts:9