#class decorator allows undefined method call?

4 messages · Page 1 of 1 (latest)

short lanternBOT
#
andreaelektronvolt#0

Preview:```ts
const SYM = Symbol("foo")
const SYM2 = Symbol("bar")

interface X {
[SYM]: true
}

function decorator<
T extends {new (...args: any[]): any}

(base: T) {
return class extends base implements X {
constructor(...args: any[]) {
sup
...```

obsidian burrow
#

Apparently line 30 is "allowed" by the typescript compiler

#

?

#

shorter example on line 22