highlight.js: support v9.1.0

* expose hljs.COMMENT()
* IModeBase.begin and IModeBase.end accept types string and RegExp
This commit is contained in:
Charly Delay
2016-01-27 12:28:08 +01:00
parent 46719185c5
commit 2da55a0904
+8 -3
View File
@@ -1,4 +1,4 @@
// Type definitions for highlight.js v8.2.0
// Type definitions for highlight.js v9.1.0
// Project: https://github.com/isagalaev/highlight.js
// Definitions by: Niklas Mollenhauer <https://github.com/nikeee/>, Jeremy Hull <https://github.com/sourrust>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
@@ -35,6 +35,11 @@ declare module hljs
export function inherit(parent: Object, obj: Object): Object;
export function COMMENT(
begin: (string|RegExp),
end: (string|RegExp),
inherits: IModeBase): IMode;
// Common regexps
export var IDENT_RE: string;
export var UNDERSCORE_IDENT_RE: string;
@@ -111,8 +116,8 @@ declare module hljs
{
className?: string;
aliases?: string[];
begin?: string;
end?: string;
begin?: (string|RegExp);
end?: (string|RegExp);
case_insensitive?: boolean;
beginKeyword?: string;
endsWithParent?: boolean;