diff --git a/types/hast/hast-tests.ts b/types/hast/hast-tests.ts index 68699d6dd3..595c642818 100644 --- a/types/hast/hast-tests.ts +++ b/types/hast/hast-tests.ts @@ -73,6 +73,9 @@ const properties: Properties = { propertyName2: ['propertyValue2', 'propertyValue3'], propertyName3: true, propertyName4: 47, + propertyName5: [4, "4"], + propertyName6: null, + propertyName7: undefined }; function getElement(): Element { diff --git a/types/hast/index.d.ts b/types/hast/index.d.ts index 85aa548b3b..dd08f9da82 100644 --- a/types/hast/index.d.ts +++ b/types/hast/index.d.ts @@ -2,6 +2,7 @@ // Project: https://github.com/syntax-tree/hast // Definitions by: lukeggchapman // Junyoung Choi +// Christian Murphy // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 3.0 @@ -72,7 +73,7 @@ export interface Element extends Parent { * Represents information associated with an element. */ export interface Properties { - [PropertyName: string]: any; + [PropertyName: string]: boolean | number | string | null | undefined | Array; } /**