class Some<AttributeType = {
bar: string
}> {
foo(attrs: AttributeType) {
if (attrs.bar) {
console.log(attrs.bar)
}
}
}
Unable to run TypeScript code due to a specific error message:
Property 'bar' does not exist on type 'AttributeType'.