Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make skipLibCheck overridable #1617

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog

## 9.4.4
* [Bug fix: let users override skipLibCheck](https://github.com/TypeStrong/ts-loader/pull/1617) - thanks @haakonflatval-cognite

## 9.4.3
* [Bug fix: add config file as build dependency](https://github.com/TypeStrong/ts-loader/pull/1611) - thanks @alexander-akait

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ts-loader",
"version": "9.4.3",
"version": "9.4.4",
"description": "TypeScript loader for webpack",
"main": "index.js",
"types": "dist",
Expand Down
13 changes: 9 additions & 4 deletions src/compilerSetup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,15 @@ export function getCompilerOptions(
configParseResult: typescript.ParsedCommandLine,
compiler: typeof typescript
) {
const compilerOptions = Object.assign({}, configParseResult.options, {
skipLibCheck: true,
suppressOutputPathCheck: true, // This is why: https://github.com/Microsoft/TypeScript/issues/7363
} as typescript.CompilerOptions);
const defaultOptions = { skipLibCheck: true };

const compilerOptions = Object.assign(
defaultOptions,
configParseResult.options,
{
suppressOutputPathCheck: true, // This is why: https://github.com/Microsoft/TypeScript/issues/7363
} as typescript.CompilerOptions
);

// if `module` is not specified and not using ES6+ target, default to CJS module output
if (
Expand Down