Closed ElPrudi closed 1 year ago
It's fixed in the last versions.
The latest version didn't fix it for me.
What helped is to set the constructor's parameter to optional. Like so:
constructor(options?: VisualConstructorOptions) {
// Fixes stupid shitty bug: https://github.com/microsoft/PowerBI-visuals-tools/issues/428
if (!options) {
return;
}
// DO YOUR STUFF
}
@Syntarex Thanks for additional info. Yes, this is necessary to do it in your constructor, because now options
is optional. It was did this way to match PowerBI API and allow to use it in strict mode.
When I enable
"strict": true
in my tsconfig.json, I get these errors:I can't exclude it from my tsconfig, as it has a direct dependency to the visual.ts in the src folder.