Closed
Description
The recent update on gts
included new settings for tsconfig.json
. Specifically, it turned on useDefineForClassFields
. And this changes the Typescript behavior in how/when class properties get initialized.
Related: microsoft/TypeScript#45995 (comment)
The task for this Issue with regards to sass-parser
is to find all properties initialized with !
, and replace them with a declare
statement, for example:
class X {
// BAD:
_foo!: string;
}
class X {
// GOOD:
declare _foo: string;
}
Otherwise, the observed behavior for our PostCSS subnode classes is that all the values get reset after they get initialized to their "default" values.