Add a test for partials referencing paths.
This commit is contained in:
parent
df9ebaf0e0
commit
97fbde6304
1
js/test_cases/partial_path/greeting.dust
Normal file
1
js/test_cases/partial_path/greeting.dust
Normal file
@ -0,0 +1 @@
|
|||||||
|
Hello {name}{?item}, nice {item}{/item}!{~n}
|
14
js/test_cases/partial_path/input1.json
Normal file
14
js/test_cases/partial_path/input1.json
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
{
|
||||||
|
"people": [
|
||||||
|
{
|
||||||
|
"name": "Alice",
|
||||||
|
"item": "cat"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Bob"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"globals": {
|
||||||
|
"item": "couch"
|
||||||
|
}
|
||||||
|
}
|
3
js/test_cases/partial_path/main.dust
Normal file
3
js/test_cases/partial_path/main.dust
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{#people}
|
||||||
|
{>greeting item=globals.item/}
|
||||||
|
{/people}
|
Loading…
x
Reference in New Issue
Block a user