Microsoft/TypeScript
Ver no GitHubUnknown interface "ClassMethodDecoratorFunction" in documentation for 5.0.4 lib.decorators.d.ts
Open
#54.099 aberto em 2 de mai. de 2023
BugDomain: DecoratorsHelp Wanted
Métricas do repositório
- Stars
- (48.455 stars)
- Métricas de merge de PR
- (Mesclagem média 6d 17h) (9 fundiu PRs em 30d)
Description
lib Update Request
Configuration Check
My compilation target is ES2021 and my lib is ["es2017", "dom"].
Missing / Incorrect Definition
The mentioned example:
const bound: ClassMethodDecoratorFunction = (value, context) {
if (context.private) throw new TypeError("Not supported on private methods.");
context.addInitializer(function () {
this[context.name] = this[context.name].bind(this);
});
}
Uses an Interface ClassMethodDecoratorFunction which isn't implemented - as far as I can tell this should be ClassMethodDecoratorContext instead