tsc-mixeddeprecated

Run tsc with a configuration and files.

Usage no npm install needed!

<script type="module">
  import tscMixed from 'https://cdn.skypack.dev/tsc-mixed';
</script>

README

tsc-mixed

📠 ️Run tsc with a configuration and files.

build npm license

Introduction

tsc-mixed builds upon TypeScript's own tsc to circumvent its TS5042 error.

tsc --project tsconfig.json index.ts

# error TS5042: Option "project" cannot be mixed with source files on a command line.

Installation

Yarn

yarn add -D tsc-mixed

npm

npm install --save-dev tsc-mixed

Usage

Use it as a drop-in tsc replacement.

tsc-mixed --project tsconfig.json index.ts

lint-staged

Use it with lint-staged to only type check staged files.

{
  "**/*.{ts,tsx}": ["tsc-mixed --project tsconfig.json"]
}