Pārlūkot izejas kodu

Test view with functions from cli

Tests #717 for cli which allows use of functions in a view which is
exported javascript.
pull/717/head
Justin Staubach pirms 6 gadiem
vecāks
revīzija
4221728e6f
3 mainītis faili ar 10 papildinājumiem un 0 dzēšanām
  1. +8
    -0
      test/_files/cli_js_view_with_function.js
  2. +1
    -0
      test/_files/cli_js_view_with_function.mustache
  3. +1
    -0
      test/_files/cli_js_view_with_function.txt

+ 8
- 0
test/_files/cli_js_view_with_function.js Parādīt failu

@@ -0,0 +1,8 @@
module.exports = {
'name': 'Tater',
'bold': function () {
return function (text, render) {
return '<b>' + render(text) + '</b>';
};
}
};

+ 1
- 0
test/_files/cli_js_view_with_function.mustache Parādīt failu

@@ -0,0 +1 @@
{{#bold}}Hi {{name}}.{{/bold}}

+ 1
- 0
test/_files/cli_js_view_with_function.txt Parādīt failu

@@ -0,0 +1 @@
<b>Hi Tater.</b>

Notiek ielāde…
Atcelt
Saglabāt