ing
This commit is contained in:
parent
da4e5c50a8
commit
529d717588
|
@ -22,7 +22,8 @@
|
|||
"build": "npm run bundle && npm run generate:package && npm run generate:doc"
|
||||
},
|
||||
"dependencies": {
|
||||
"@loafer/core": "^0.0.1"
|
||||
"@loafer/core": "^0.0.1",
|
||||
"reflect-metadata": "^0.1.12"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/jasmine": "~2.8.5",
|
||||
|
|
|
@ -24,7 +24,7 @@ import { NotSupportedDecoratorError } from './error';
|
|||
export class DecoratorHelper {
|
||||
|
||||
public static register<AnnotationType extends Annotation>(annotation: AnnotationType, ...decoratorArgs: any[]) {
|
||||
const annotationClass = TypeUtil.getType(annotation);
|
||||
const annotationClass = Metadata.getType(annotation);
|
||||
const name: string = annotationClass.name;
|
||||
|
||||
DecoratorHelper.registerAnnotation(name, annotation, decoratorArgs);
|
||||
|
@ -46,7 +46,7 @@ export class DecoratorHelper {
|
|||
|
||||
const [target, propertyKey, descriptorOrParameterIndex] = decoratorArgs;
|
||||
|
||||
const clazz: Class = Class._defineClass(TypeUtil.getType(target));
|
||||
const clazz: Class = Class._defineClass(Metadata.getType(target));
|
||||
let field: Field = null;
|
||||
let method: Method = null;
|
||||
let parameter: Parameter = null;
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
"node_modules/@types"
|
||||
],
|
||||
"types": [
|
||||
"reflect-metadata"
|
||||
],
|
||||
"lib": [
|
||||
"es2015", "es2016", "es2017", "dom"
|
||||
|
|
Loading…
Reference in New Issue
Block a user