Skip to content

Commit

Permalink
blear.classes.template
Browse files Browse the repository at this point in the history
  • Loading branch information
cloudcome committed May 24, 2016
1 parent a3c8f26 commit 5981e59
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "blear.classes.template",
"version": "1.0.7",
"version": "1.0.8",
"description": "指令类型模板引擎",
"scripts": {
"live": "browser-sync start --config bs-config.js",
Expand Down
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,7 @@ pro[_TAG_OPEN] = function (token) {
var lastName = '';
var type = token.value;
var value = token.value;
var tag = value;
var tag = value.toLocaleLowerCase();
var isDirective = false;
var directiveName;

Expand Down
7 changes: 4 additions & 3 deletions test/test.index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,12 @@ var Template = require('../src/index.js');


describe('测试文件', function () {
it('<!doctype html>', function () {
var template = '<!doctype html>';
it('<!DOCTYPE html>', function () {
var template = '<!DOCTYPE html><HTML>123</html>';
var template2 = '<!doctype html><html>123</html>';
var tpl = new Template(template);
var html = tpl.render({});
expect(html).toEqual(template);
expect(html).toEqual(template2);
});

it('{{varible}}', function (done) {
Expand Down

0 comments on commit 5981e59

Please sign in to comment.