[![logo][]](https://xylabs.com)

# @xylabs/tsconfig-dom

[![npm][npm-badge]][npm-link]
[![license][license-badge]][license-link]

> Typescript Base Config used throughout XY Labs TypeScript/JavaScript libraries and react projects

## Install

Using npm:

```sh
npm install -D {{name}} @xylabs/tsconfig
```

Using yarn:

```sh
yarn add -D {{name}} @xylabs/tsconfig
```

Using pnpm:

```sh
pnpm add -D {{name}} @xylabs/tsconfig
```

Using bun:

```sh
bun add -D {{name}} @xylabs/tsconfig
```

## Usage

Extend this config in your project's `tsconfig.json`:

```json
{
  "extends": "@xylabs/tsconfig-dom",
  "compilerOptions": {
    "outDir": "./dist"
  },
  "include": ["src"]
}
```

This extends [`@xylabs/tsconfig`](https://www.npmjs.com/package/@xylabs/tsconfig) and adds `DOM` and `DOM.Iterable` to the `lib` array, making browser APIs like `window`, `document`, and DOM iterables available.

For React projects, use [`@xylabs/tsconfig-react`](https://www.npmjs.com/package/@xylabs/tsconfig-react) which extends this config with JSX support.


## License

See the [LICENSE](LICENSE) file for license rights and limitations (LGPL-3.0-only).

## Credits

[Made with 🔥 and ❄️ by XY Labs](https://xylabs.com)

[npm-badge]: https://img.shields.io/npm/v/@xylabs/tsconfig-dom.svg
[npm-link]: https://www.npmjs.com/package/@xylabs/tsconfig-dom
[license-badge]: https://img.shields.io/npm/l/@xylabs/tsconfig-dom.svg
[license-link]: https://github.com/xylabs/sdk-js/blob/main/LICENSE
[logo]: https://cdn.xy.company/img/brand/XYPersistentCompany_Logo_Icon_Colored.svg
