このサイトはJavaScriptを使用しています
ホーム
エクスプローラー
ヘルプ
サインイン
jan
/
mustache.js
ミラー元
https://github.com/janl/mustache.js
ウォッチ
1
スター
0
フォーク
0
コード
課題
0
リリース
46
Wiki
アクティビティ
選択できるのは25トピックまでです。
トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。
826
コミット
19
ブランチ
33MB
ツリー:
af216b0ce7
8-as-legacy
master
remove-build-output-from-git
0.4.x
browser-tests-on-8
fix_commonjs
gh-pages
greenkeeper-chai-3.4.0
greenkeeper-chai-4.0.0
greenkeeper-chai-4.0.1
greenkeeper-eslint-1.5.1
greenkeeper-mocha-2.3.3
greenkeeper-mocha-3.3.0
greenkeeper-mocha-3.4.0
greenkeeper-pin
helpers
new-build-system
parser-rewrite
with-js-extras
v4.2.0
v4.1.0
v4.0.1
v4.0.0
v3.2.1
v3.2.0
v3.1.0
v3.0.3
v3.0.2
v3.0.1
v3.0.0
v2.3.2
v2.3.1
v2.3.0
v2.2.1
v2.2.0
v2.1.3
v2.1.2
v2.1.1
v2.1.0
v2.0.0
v1.2.0
v1.1.0
v1.0.0
0.8.2
0.8.1
0.8.0
0.7.3
0.7.2
0.7.1
0.7.0
0.6.0
0.5.2
0.5.2-vsc
0.5.1
0.5.1-vsc
0.5.0-vsc
0.4.2
0.4.1
0.4.0
0.3.0
0.2.3
0.2.2
0.2.1
0.2
0.1
ブランチ
タグ
${ item.name }
ブランチ
${ searchTerm }
を作成
'af216b0ce7' から
${ noResults }
mustache.js
/
test
/
_files
/
check_falsy.js
check_falsy.js
119B
Raw
通常表示
履歴
Don't evaluate lambdas that return falsy values as an empty string. Issue: If I create a Mustache lambda to return numbers and I expect 0 to be of those numbers, I'll instead only receive an empty string for 0 because it evaluates to falsy. Fix: Check the result of the lambda to be undefined or null. Only then should it return the empty string.
13年前
Start linting all test/ files as part of test script (#704) In an effort of ensuring consistent code style in test files as with the "production" source code, we should run eslint as part of the `$ npm test` script as well. Most of the related fixes was done by `eslint` using the `--fix` argument. Only special configuration tweaks for tests compared to the other source code, is to allow functions declaration without names. The rationale for allowing that in tests, is that the important reason we have them in the source code (proper stacktraces) aren't as important in test files.
6年前
Don't evaluate lambdas that return falsy values as an empty string. Issue: If I create a Mustache lambda to return numbers and I expect 0 to be of those numbers, I'll instead only receive an empty string for 0 because it evaluates to falsy. Fix: Check the result of the lambda to be undefined or null. Only then should it return the empty string.
13年前
Start linting all test/ files as part of test script (#704) In an effort of ensuring consistent code style in test files as with the "production" source code, we should run eslint as part of the `$ npm test` script as well. Most of the related fixes was done by `eslint` using the `--fix` argument. Only special configuration tweaks for tests compared to the other source code, is to allow functions declaration without names. The rationale for allowing that in tests, is that the important reason we have them in the source code (proper stacktraces) aren't as important in test files.
6年前
Don't evaluate lambdas that return falsy values as an empty string. Issue: If I create a Mustache lambda to return numbers and I expect 0 to be of those numbers, I'll instead only receive an empty string for 0 because it evaluates to falsy. Fix: Check the result of the lambda to be undefined or null. Only then should it return the empty string.
13年前
Start linting all test/ files as part of test script (#704) In an effort of ensuring consistent code style in test files as with the "production" source code, we should run eslint as part of the `$ npm test` script as well. Most of the related fixes was done by `eslint` using the `--fix` argument. Only special configuration tweaks for tests compared to the other source code, is to allow functions declaration without names. The rationale for allowing that in tests, is that the important reason we have them in the source code (proper stacktraces) aren't as important in test files.
6年前
1
2
3
4
5
6
7
({
number: function (text, render) {
return function (text, render) {
return +render(text);
};
}
});