simple-html-tokenizer
Advanced tools
Comparing version 0.5.2 to 0.5.3
@@ -103,3 +103,3 @@ /** | ||
} | ||
else if (isAlpha(char)) { | ||
else if (char === '@' || isAlpha(char)) { | ||
this.transitionTo("tagName" /* tagName */); | ||
@@ -395,3 +395,3 @@ this.tagNameBuffer = ''; | ||
var char = this.consume(); | ||
if (isAlpha(char)) { | ||
if (char === '@' || isAlpha(char)) { | ||
this.transitionTo("tagName" /* tagName */); | ||
@@ -398,0 +398,0 @@ this.tagNameBuffer = ''; |
@@ -109,3 +109,3 @@ (function (global, factory) { | ||
} | ||
else if (isAlpha(char)) { | ||
else if (char === '@' || isAlpha(char)) { | ||
this.transitionTo("tagName" /* tagName */); | ||
@@ -401,3 +401,3 @@ this.tagNameBuffer = ''; | ||
var char = this.consume(); | ||
if (isAlpha(char)) { | ||
if (char === '@' || isAlpha(char)) { | ||
this.transitionTo("tagName" /* tagName */); | ||
@@ -404,0 +404,0 @@ this.tagNameBuffer = ''; |
@@ -157,2 +157,7 @@ (function (global, factory) { | ||
}); | ||
// https://github.com/emberjs/rfcs/blob/master/text/0311-angle-bracket-invocation.md#dynamic-invocations | ||
QUnit.test('An Emberish named arg invocation', function (assert) { | ||
var tokens = simpleHtmlTokenizer.tokenize('<@foo></@foo>'); | ||
assert.deepEqual(tokens, [startTag('@foo'), endTag('@foo')]); | ||
}); | ||
QUnit.module('simple-html-tokenizer - preprocessing'); | ||
@@ -159,0 +164,0 @@ QUnit.test('Carriage returns are replaced with line feeds', function (assert) { |
{ | ||
"name": "simple-html-tokenizer", | ||
"version": "0.5.2", | ||
"version": "0.5.3", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "description": "Simple HTML Tokenizer is a lightweight JavaScript library that can be used to tokenize the kind of HTML normally found in templates.", |
@@ -160,3 +160,3 @@ import { preprocessInput, isAlpha, isSpace } from './utils'; | ||
this.transitionTo(TokenizerState.endTagOpen); | ||
} else if (isAlpha(char)) { | ||
} else if (char === '@' || isAlpha(char)) { | ||
this.transitionTo(TokenizerState.tagName); | ||
@@ -452,3 +452,3 @@ this.tagNameBuffer = ''; | ||
if (isAlpha(char)) { | ||
if (char === '@' || isAlpha(char)) { | ||
this.transitionTo(TokenizerState.tagName); | ||
@@ -455,0 +455,0 @@ this.tagNameBuffer = ''; |
@@ -210,2 +210,8 @@ import { | ||
// https://github.com/emberjs/rfcs/blob/master/text/0311-angle-bracket-invocation.md#dynamic-invocations | ||
QUnit.test('An Emberish named arg invocation', function(assert) { | ||
let tokens = tokenize('<@foo></@foo>'); | ||
assert.deepEqual(tokens, [startTag('@foo'), endTag('@foo')]); | ||
}); | ||
QUnit.module('simple-html-tokenizer - preprocessing'); | ||
@@ -212,0 +218,0 @@ |
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
946660
10360