Greetings.
My setup is Aurelia 1 + TypeScript + dumber.
I am encountering a strange problem with this (simplified) setup which involves class inheritance and DialogService.
In short:
- base component which opens a dialog using its class as the viewModel
- two derived components
- page which requires both components
At runtime, the page breaks with the following error:
Edge:
TypeError: Class extends value undefined is not a constructor or null
Firefox:
TypeError: class heritage inspectionAnswerListBase_1.InspectionAnswerListBase is not an object or null
What happens is that the first component works correctly, but in the second one the base class is undefined
. Note that this is not dependent on the actual components but only in their order (the first works, the second breaks).
However, specifying the viewModel for the dialog as a module path (string) instead of an import DOES work.
Out tsconfig.json
is:
{
"compileOnSave": false,
"compilerOptions": {
"rootDir": "src/",
"sourceMap": true,
"target": "ES2017",
"module": "AMD",
"declaration": false,
"removeComments": true,
"importHelpers": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"noEmitOnError": true,
"forceConsistentCasingInFileNames": true,
"moduleResolution": "node",
"esModuleInterop": true,
"alwaysStrict": true,
"strictBindCallApply": true,
"noImplicitThis": true,
"noImplicitAny": false,
"noImplicitOverride": true
},
"exclude": [
"node_modules",
"obj",
"bin"
]
}
I do not seem to be able to pinpoint the exact source of the problem, I suspect some odd edge case.
I am not even sure whether I should expect a solution, but maybe something here rings a bell for someone.