Skip to content
This repository has been archived by the owner on Dec 1, 2019. It is now read-only.

Fix: Add hack to stop null exception #337

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
4 changes: 4 additions & 0 deletions src/instance.ts
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,10 @@ function setupBabel(loaderConfig: LoaderConfig): any {
}

function applyDefaults(configFilePath: string, compilerConfig: TsConfig, loaderConfig: LoaderConfig) {
// HACK: adding in a blank initializer to stop loader from crashing,
// see s-panferov/awesome-typescript-loader#190 for more details
compilerConfig.raw.compilerOptions.exclude = compilerConfig.raw.compilerOptions.exclude || [];

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the crash was in 2.2.4 and not in master so this fix doesn't apply. The line that was crashing isn't even here: compilerConfig.typingOptions.exclude = compilerConfig.typingOptions.exclude || [];


_.defaults(compilerConfig.options, {
sourceMap: true,
verbose: false,
Expand Down