@glimmer/syntax
Advanced tools
Comparing version 0.77.4 to 0.77.5
@@ -19,3 +19,3 @@ "use strict"; | ||
*/ | ||
function tokensFromType(node, scopedTokens) { | ||
function tokensFromType(node, scopedTokens, options) { | ||
if (node.type === 'PathExpression') { | ||
@@ -41,2 +41,6 @@ if (node.head.type === 'AtHead' || node.head.type === 'ThisHead') { | ||
if (!options.includeHtmlElements && tag.indexOf('.') === -1 && tag.toLowerCase() === tag) { | ||
return; | ||
} | ||
if (tag.substr(0, 5) === 'this.') { | ||
@@ -58,4 +62,4 @@ return; | ||
function addTokens(tokensSet, node, scopedTokens) { | ||
const maybeTokens = tokensFromType(node, scopedTokens); | ||
function addTokens(tokensSet, node, scopedTokens, options) { | ||
const maybeTokens = tokensFromType(node, scopedTokens, options); | ||
(Array.isArray(maybeTokens) ? maybeTokens : [maybeTokens]).forEach(maybeToken => { | ||
@@ -74,3 +78,6 @@ if (maybeToken !== undefined && maybeToken[0] !== '@') { | ||
function getTemplateLocals(html, options) { | ||
function getTemplateLocals(html, options = { | ||
includeHtmlElements: false, | ||
includeKeywords: false | ||
}) { | ||
const ast = (0, _tokenizerEventHandlers.preprocess)(html); | ||
@@ -103,3 +110,3 @@ const tokensSet = new Set(); | ||
}); | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
}, | ||
@@ -118,3 +125,3 @@ | ||
PathExpression(node) { | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
} | ||
@@ -132,2 +139,2 @@ | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL3N5bnRheC9saWIvZ2V0LXRlbXBsYXRlLWxvY2Fscy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7O0FBQUE7O0FBQ0E7O0FBQ0E7Oz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Rva2Vucyh0b2tlbnNTZXQsIG5vZGUsIHNjb3BlZFRva2Vucywgb3B0aW9ucyk7XG4gICAgICB9LFxuXG4gICAgICBleGl0KHsgYmxvY2tQYXJhbXMgfSkge1xuICAgICAgICBibG9ja1BhcmFtcy5mb3JFYWNoKCgpID0+IHtcbiAgICAgICAgICBzY29wZWRUb2tlbnMucG9wKCk7XG4gICAgICAgIH0pO1xuICAgICAgfSxcbiAgICB9LFxuXG4gICAgUGF0aEV4cHJlc3Npb24obm9kZSkge1xuICAgICAgYWRkVG9rZW5zKHRva2Vuc1NldCwgbm9kZSwgc2NvcGVkVG9rZW5zLCBvcHRpb25zKTtcbiAgICB9LFxuICB9KTtcblxuICBsZXQgdG9rZW5zOiBzdHJpbmdbXSA9IFtdO1xuXG4gIHRva2Vuc1NldC5mb3JFYWNoKChzKSA9PiB0b2tlbnMucHVzaChzKSk7XG5cbiAgaWYgKCFvcHRpb25zPy5pbmNsdWRlS2V5d29yZHMpIHtcbiAgICB0b2tlbnMgPSB0b2tlbnMuZmlsdGVyKCh0b2tlbikgPT4gIWlzS2V5d29yZCh0b2tlbikpO1xuICB9XG5cbiAgcmV0dXJuIHRva2Vucztcbn1cbiJdLCJzb3VyY2VSb290IjoiIn0= |
@@ -19,3 +19,3 @@ "use strict"; | ||
*/ | ||
function tokensFromType(node, scopedTokens) { | ||
function tokensFromType(node, scopedTokens, options) { | ||
if (node.type === 'PathExpression') { | ||
@@ -40,2 +40,6 @@ if (node.head.type === 'AtHead' || node.head.type === 'ThisHead') { | ||
if (!options.includeHtmlElements && tag.indexOf('.') === -1 && tag.toLowerCase() === tag) { | ||
return; | ||
} | ||
if (tag.substr(0, 5) === 'this.') { | ||
@@ -57,4 +61,4 @@ return; | ||
function addTokens(tokensSet, node, scopedTokens) { | ||
var maybeTokens = tokensFromType(node, scopedTokens); | ||
function addTokens(tokensSet, node, scopedTokens, options) { | ||
var maybeTokens = tokensFromType(node, scopedTokens, options); | ||
(Array.isArray(maybeTokens) ? maybeTokens : [maybeTokens]).forEach(function (maybeToken) { | ||
@@ -74,2 +78,9 @@ if (maybeToken !== undefined && maybeToken[0] !== '@') { | ||
function getTemplateLocals(html, options) { | ||
if (options === void 0) { | ||
options = { | ||
includeHtmlElements: false, | ||
includeKeywords: false | ||
}; | ||
} | ||
var ast = (0, _tokenizerEventHandlers.preprocess)(html); | ||
@@ -98,3 +109,3 @@ var tokensSet = new Set(); | ||
}); | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
}, | ||
@@ -109,3 +120,3 @@ exit: function exit(_ref3) { | ||
PathExpression: function PathExpression(node) { | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
} | ||
@@ -126,2 +137,2 @@ }); | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL3N5bnRheC9saWIvZ2V0LXRlbXBsYXRlLWxvY2Fscy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7O0FBQUE7O0FBQ0E7O0FBQ0E7Ozs7QUFHQTs7O0FBR0EsU0FBQSxjQUFBLENBQUEsSUFBQSxFQUFBLFlBQUEsRUFBZ0U7QUFDOUQsTUFBSSxJQUFJLENBQUosSUFBQSxLQUFKLGdCQUFBLEVBQW9DO0FBQ2xDLFFBQUksSUFBSSxDQUFKLElBQUEsQ0FBQSxJQUFBLEtBQUEsUUFBQSxJQUErQixJQUFJLENBQUosSUFBQSxDQUFBLElBQUEsS0FBbkMsVUFBQSxFQUFrRTtBQUNoRTtBQUNEOztBQUVELFFBQU0sWUFBWSxHQUFHLElBQUksQ0FBSixJQUFBLENBQXJCLElBQUE7O0FBRUEsUUFBSSxZQUFZLENBQVosT0FBQSxDQUFBLFlBQUEsTUFBdUMsQ0FBM0MsQ0FBQSxFQUErQztB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XG4gICAgICAgIH0pO1xuICAgICAgfSxcbiAgICB9LFxuXG4gICAgRWxlbWVudE5vZGU6IHtcbiAgICAgIGVudGVyKG5vZGUpIHtcbiAgICAgICAgbm9kZS5ibG9ja1BhcmFtcy5mb3JFYWNoKChwYXJhbSkgPT4ge1xuICAgICAgICAgIHNjb3BlZFRva2Vucy5wdXNoKHBhcmFtKTtcbiAgICAgICAgfSk7XG4gICAgICAgIGFkZFRva2Vucyh0b2tlbnNTZXQsIG5vZGUsIHNjb3BlZFRva2Vucywgb3B0aW9ucyk7XG4gICAgICB9LFxuXG4gICAgICBleGl0KHsgYmxvY2tQYXJhbXMgfSkge1xuICAgICAgICBibG9ja1BhcmFtcy5mb3JFYWNoKCgpID0+IHtcbiAgICAgICAgICBzY29wZWRUb2tlbnMucG9wKCk7XG4gICAgICAgIH0pO1xuICAgICAgfSxcbiAgICB9LFxuXG4gICAgUGF0aEV4cHJlc3Npb24obm9kZSkge1xuICAgICAgYWRkVG9rZW5zKHRva2Vuc1NldCwgbm9kZSwgc2NvcGVkVG9rZW5zLCBvcHRpb25zKTtcbiAgICB9LFxuICB9KTtcblxuICBsZXQgdG9rZW5zOiBzdHJpbmdbXSA9IFtdO1xuXG4gIHRva2Vuc1NldC5mb3JFYWNoKChzKSA9PiB0b2tlbnMucHVzaChzKSk7XG5cbiAgaWYgKCFvcHRpb25zPy5pbmNsdWRlS2V5d29yZHMpIHtcbiAgICB0b2tlbnMgPSB0b2tlbnMuZmlsdGVyKCh0b2tlbikgPT4gIWlzS2V5d29yZCh0b2tlbikpO1xuICB9XG5cbiAgcmV0dXJuIHRva2Vucztcbn1cbiJdLCJzb3VyY2VSb290IjoiIn0= |
@@ -8,3 +8,3 @@ import { isKeyword } from './keywords'; | ||
function tokensFromType(node, scopedTokens) { | ||
function tokensFromType(node, scopedTokens, options) { | ||
if (node.type === 'PathExpression') { | ||
@@ -30,2 +30,6 @@ if (node.head.type === 'AtHead' || node.head.type === 'ThisHead') { | ||
if (!options.includeHtmlElements && tag.indexOf('.') === -1 && tag.toLowerCase() === tag) { | ||
return; | ||
} | ||
if (tag.substr(0, 5) === 'this.') { | ||
@@ -47,4 +51,4 @@ return; | ||
function addTokens(tokensSet, node, scopedTokens) { | ||
const maybeTokens = tokensFromType(node, scopedTokens); | ||
function addTokens(tokensSet, node, scopedTokens, options) { | ||
const maybeTokens = tokensFromType(node, scopedTokens, options); | ||
(Array.isArray(maybeTokens) ? maybeTokens : [maybeTokens]).forEach(maybeToken => { | ||
@@ -63,3 +67,6 @@ if (maybeToken !== undefined && maybeToken[0] !== '@') { | ||
export function getTemplateLocals(html, options) { | ||
export function getTemplateLocals(html, options = { | ||
includeHtmlElements: false, | ||
includeKeywords: false | ||
}) { | ||
const ast = preprocess(html); | ||
@@ -92,3 +99,3 @@ const tokensSet = new Set(); | ||
}); | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
}, | ||
@@ -107,3 +114,3 @@ | ||
PathExpression(node) { | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
} | ||
@@ -121,2 +128,2 @@ | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL3N5bnRheC9saWIvZ2V0LXRlbXBsYXRlLWxvY2Fscy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxTQUFTLFNBQVQsUUFBMEIsWUFBMUI7QUFDQSxTQUFTLFVBQVQsUUFBMkIsbUNBQTNCO0FBQ0EsT0FBTyxRQUFQLE1BQXFCLHNCQUFyQjtBQUdBOzs7O0FBR0EsU0FBUyxjQUFULENBQXdCLElBQXhCLEVBQTBDLFlBQTFDLEVBQWdFO0FBQzlELE1BQUksSUFBSSxDQUFDLElBQUwsS0FBYyxnQkFBbEIsRUFBb0M7QUFDbEMsUU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biAgICAgICAgbm9kZS5ibG9ja1BhcmFtcy5mb3JFYWNoKChwYXJhbSkgPT4ge1xuICAgICAgICAgIHNjb3BlZFRva2Vucy5wdXNoKHBhcmFtKTtcbiAgICAgICAgfSk7XG4gICAgICAgIGFkZFRva2Vucyh0b2tlbnNTZXQsIG5vZGUsIHNjb3BlZFRva2Vucywgb3B0aW9ucyk7XG4gICAgICB9LFxuXG4gICAgICBleGl0KHsgYmxvY2tQYXJhbXMgfSkge1xuICAgICAgICBibG9ja1BhcmFtcy5mb3JFYWNoKCgpID0+IHtcbiAgICAgICAgICBzY29wZWRUb2tlbnMucG9wKCk7XG4gICAgICAgIH0pO1xuICAgICAgfSxcbiAgICB9LFxuXG4gICAgUGF0aEV4cHJlc3Npb24obm9kZSkge1xuICAgICAgYWRkVG9rZW5zKHRva2Vuc1NldCwgbm9kZSwgc2NvcGVkVG9rZW5zLCBvcHRpb25zKTtcbiAgICB9LFxuICB9KTtcblxuICBsZXQgdG9rZW5zOiBzdHJpbmdbXSA9IFtdO1xuXG4gIHRva2Vuc1NldC5mb3JFYWNoKChzKSA9PiB0b2tlbnMucHVzaChzKSk7XG5cbiAgaWYgKCFvcHRpb25zPy5pbmNsdWRlS2V5d29yZHMpIHtcbiAgICB0b2tlbnMgPSB0b2tlbnMuZmlsdGVyKCh0b2tlbikgPT4gIWlzS2V5d29yZCh0b2tlbikpO1xuICB9XG5cbiAgcmV0dXJuIHRva2Vucztcbn1cbiJdLCJzb3VyY2VSb290IjoiIn0= |
@@ -8,3 +8,3 @@ import { isKeyword } from './keywords'; | ||
function tokensFromType(node, scopedTokens) { | ||
function tokensFromType(node, scopedTokens, options) { | ||
if (node.type === 'PathExpression') { | ||
@@ -29,2 +29,6 @@ if (node.head.type === 'AtHead' || node.head.type === 'ThisHead') { | ||
if (!options.includeHtmlElements && tag.indexOf('.') === -1 && tag.toLowerCase() === tag) { | ||
return; | ||
} | ||
if (tag.substr(0, 5) === 'this.') { | ||
@@ -46,4 +50,4 @@ return; | ||
function addTokens(tokensSet, node, scopedTokens) { | ||
var maybeTokens = tokensFromType(node, scopedTokens); | ||
function addTokens(tokensSet, node, scopedTokens, options) { | ||
var maybeTokens = tokensFromType(node, scopedTokens, options); | ||
(Array.isArray(maybeTokens) ? maybeTokens : [maybeTokens]).forEach(function (maybeToken) { | ||
@@ -63,2 +67,9 @@ if (maybeToken !== undefined && maybeToken[0] !== '@') { | ||
export function getTemplateLocals(html, options) { | ||
if (options === void 0) { | ||
options = { | ||
includeHtmlElements: false, | ||
includeKeywords: false | ||
}; | ||
} | ||
var ast = preprocess(html); | ||
@@ -87,3 +98,3 @@ var tokensSet = new Set(); | ||
}); | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
}, | ||
@@ -98,3 +109,3 @@ exit: function exit(_ref3) { | ||
PathExpression: function PathExpression(node) { | ||
addTokens(tokensSet, node, scopedTokens); | ||
addTokens(tokensSet, node, scopedTokens, options); | ||
} | ||
@@ -115,2 +126,2 @@ }); | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL3N5bnRheC9saWIvZ2V0LXRlbXBsYXRlLWxvY2Fscy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxTQUFBLFNBQUEsUUFBQSxZQUFBO0FBQ0EsU0FBQSxVQUFBLFFBQUEsbUNBQUE7QUFDQSxPQUFBLFFBQUEsTUFBQSxzQkFBQTtBQUdBOzs7O0FBR0EsU0FBQSxjQUFBLENBQUEsSUFBQSxFQUFBLFlBQUEsRUFBZ0U7QUFDOUQsTUFBSSxJQUFJLENBQUosSUFBQSxLQUFKLGdCQUFBLEVBQW9DO0FBQ2xDLFFBQUksSUFBSSxDQUFKLElBQUEsQ0FBQSxJQUFBLEtBQUEsUUFBQSxJQUErQixJQUFJLENBQUosSUFBQ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WVudE5vZGU6IHtcbiAgICAgIGVudGVyKG5vZGUpIHtcbiAgICAgICAgbm9kZS5ibG9ja1BhcmFtcy5mb3JFYWNoKChwYXJhbSkgPT4ge1xuICAgICAgICAgIHNjb3BlZFRva2Vucy5wdXNoKHBhcmFtKTtcbiAgICAgICAgfSk7XG4gICAgICAgIGFkZFRva2Vucyh0b2tlbnNTZXQsIG5vZGUsIHNjb3BlZFRva2Vucywgb3B0aW9ucyk7XG4gICAgICB9LFxuXG4gICAgICBleGl0KHsgYmxvY2tQYXJhbXMgfSkge1xuICAgICAgICBibG9ja1BhcmFtcy5mb3JFYWNoKCgpID0+IHtcbiAgICAgICAgICBzY29wZWRUb2tlbnMucG9wKCk7XG4gICAgICAgIH0pO1xuICAgICAgfSxcbiAgICB9LFxuXG4gICAgUGF0aEV4cHJlc3Npb24obm9kZSkge1xuICAgICAgYWRkVG9rZW5zKHRva2Vuc1NldCwgbm9kZSwgc2NvcGVkVG9rZW5zLCBvcHRpb25zKTtcbiAgICB9LFxuICB9KTtcblxuICBsZXQgdG9rZW5zOiBzdHJpbmdbXSA9IFtdO1xuXG4gIHRva2Vuc1NldC5mb3JFYWNoKChzKSA9PiB0b2tlbnMucHVzaChzKSk7XG5cbiAgaWYgKCFvcHRpb25zPy5pbmNsdWRlS2V5d29yZHMpIHtcbiAgICB0b2tlbnMgPSB0b2tlbnMuZmlsdGVyKCh0b2tlbikgPT4gIWlzS2V5d29yZCh0b2tlbikpO1xuICB9XG5cbiAgcmV0dXJuIHRva2Vucztcbn1cbiJdLCJzb3VyY2VSb290IjoiIn0= |
@@ -0,1 +1,5 @@ | ||
interface GetTemplateLocalsOptions { | ||
includeKeywords?: boolean; | ||
includeHtmlElements?: boolean; | ||
} | ||
/** | ||
@@ -6,5 +10,4 @@ * Parses and traverses a given handlebars html template to extract all template locals | ||
*/ | ||
export declare function getTemplateLocals(html: string, options?: { | ||
includeKeywords: boolean; | ||
}): string[]; | ||
export declare function getTemplateLocals(html: string, options?: GetTemplateLocalsOptions): string[]; | ||
export {}; | ||
//# sourceMappingURL=get-template-locals.d.ts.map |
{ | ||
"name": "@glimmer/syntax", | ||
"version": "0.77.4", | ||
"version": "0.77.5", | ||
"repository": "https://github.com/glimmerjs/glimmer-vm/tree/master/packages/@glimmer/syntax", | ||
"dependencies": { | ||
"@glimmer/interfaces": "0.77.4", | ||
"@glimmer/util": "0.77.4", | ||
"@glimmer/interfaces": "0.77.5", | ||
"@glimmer/util": "0.77.5", | ||
"@handlebars/parser": "~2.0.0", | ||
@@ -12,3 +12,3 @@ "simple-html-tokenizer": "^0.5.10" | ||
"devDependencies": { | ||
"@glimmer/local-debug-flags": "0.77.4", | ||
"@glimmer/local-debug-flags": "0.77.5", | ||
"@types/qunit": "^2.9.0" | ||
@@ -15,0 +15,0 @@ }, |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4119322
38079
+ Added@glimmer/interfaces@0.77.5(transitive)
+ Added@glimmer/util@0.77.5(transitive)
- Removed@glimmer/interfaces@0.77.4(transitive)
- Removed@glimmer/util@0.77.4(transitive)
Updated@glimmer/interfaces@0.77.5
Updated@glimmer/util@0.77.5