1.1.0 • Published 1 year ago

@mnrendra/types-tsconfig v1.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@mnrendra/types-tsconfig

tsconfig.json interface extended from the official and unofficial fields.

Install

npm i -D @mnrendra/types-tsconfig

Usage

import type { TSConfig } from '@mnrendra/types-tsconfig'

import { readFileSync } from 'fs'
import { resolve } from 'path'
import { cwd } from 'process'

import * as JSON5 from 'json5'

const { compilerOptions }: TSConfig = JSON5.parse(readFileSync(resolve(cwd(), 'tsconfig.json'), 'utf-8'))

console.log(compilerOptions)

Types

import type {
  TSConfig // `tsconfig.json` interface extended from the official and unofficial fields.
  // Interfaces
  BuildOptions,
  CompileOnSave,
  CompilerOptions,
  BaseURL,
  Paths,
  Exclude,
  Extends,
  Files,
  Include,
  MDX,
  References,
  TSNode,
  WatchOptions,
  TypeAcquisition
} from '@mnrendra/types-tsconfig'

License

MIT

Author

@mnrendra