@awesome-fe/translate
Version:
Translation utils
23 lines • 761 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.ngDocDirectiveTokenizer = void 0;
function ngDocDirectiveTokenizer(eat, value, silent) {
var matches = /^@(.*)/.exec(value);
if (matches) {
try {
if (silent || !matches) {
// either we are not eating (silent) or the match failed
return !!matches;
}
return eat(matches[0])({
type: 'ngDocDirective',
value: matches[1],
});
}
catch (e) {
this.file.fail('Unmatched anchor tag: ' + e.message);
}
}
}
exports.ngDocDirectiveTokenizer = ngDocDirectiveTokenizer;
//# sourceMappingURL=ng-doc-directive-tokenizer.js.map