-
Notifications
You must be signed in to change notification settings - Fork 16
/
context.yml
26 lines (22 loc) · 991 Bytes
/
context.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
default:
context:
lang: 'en'
visitor: 'ant'
node: 'cleanWater'
each_group:
src: "<r:nodes do='group' by='kpath'><p do='each_group'><r:kpath/>: <r:each join=', ' do='title'/></p></r:nodes>"
res: "<p>NP: crocodiles, status title</p><p>NDI: it's a lake</p><p>NPA: Keeping things clean !</p><p>NRC: The lake we love</p><p>NNP: parc opening</p><p>ND: water</p>"
set_var:
context:
date: '2011-05-30'
src: "<div do='set' next_date='date.advance(:years => 1)'><span do='next_date' format='%Y-%m-%d'/></div>"
res: "<div><span>2012-05-30</span></div>"
dom_id_in_each:
src: "<r:pages in='site limit 2'><li do='each'><r:dom_id/> <p id='this#{dom_id}'/></li></r:pages>"
tem: "/<li><%= var2.zip %> <p id='<%= \"this#\{var2.zip\}\" %>'></p></li>/"
res: "<li>29 <p id='this29'></p></li><li>33 <p id='this33'></p></li>"
list_else:
context:
node: status
src: "<ul do='posts'><li do='each' do='link'/><li do='else'>hop</li></ul>"
res: "<ul><li>hop</li></ul>"