We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 6404546 + 27c2be0 commit 5866b23Copy full SHA for 5866b23
source/TokenHighlighter.js
@@ -40,7 +40,7 @@ export class TokenHighlighter {
40
highlight(text : string, tokens : Array<string>) {
41
var tagsLength : number = this._wrapText('').length;
42
43
- var tokenDictionary = {};
+ var tokenDictionary = Object.create(null);
44
45
// Create a token map for easier lookup below.
46
for (var i = 0, numTokens = tokens.length; i < numTokens; i++) {
0 commit comments