Skip to content

Cannot set property 'disable' of undefined (tsconfig inheritance) #31

@YuliaTsareva

Description

@YuliaTsareva

It seems that tsconfigs with inheritance are not correctly processed.

If config looks like

{
    "extends": "./tsconfig",
    "angularCompilerOptions": {
        "genDir": "./compiled",
        "skipMetadataEmit": true
    }
}

an error occurs at text-based-loader/loader.ts because there is no compilerOptions.

Module build failed: TypeError: Cannot set property 'disable' of undefined

See https://github.com/shlomiassaf/ngc-webpack/blob/master/src/aot-clean-transformer/loader/text-based-loader/loader.ts#L269

For now I add empty compilerOptions as a workaround:

{
    "extends": "./tsconfig",
    "compilerOptions": {},
    "angularCompilerOptions": {
        "genDir": "./compiled",
        "skipMetadataEmit": true
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions