File: loop-in-object.test

package info (click to toggle)
haskell-doctemplates 0.11.0.1-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 284 kB
  • sloc: haskell: 1,223; makefile: 3
file content (19 lines) | stat: -rw-r--r-- 404 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{ "worksite":
  { "name": "canyon"
  , "workers":
       [ { "name": { "first": "John", "last": "Doe" } }
       , { "name": { "first": "Omar", "last": "Smith" }
         , "salary": "30000" }
       , { "name": { "first": "Sara", "last": "Chen" }
         , "salary": "60000" }
       ]
  }
}
.
${ for(worksite.workers) }
${it.name.last}, ${it.name.first}
${ endfor }
.
Doe, John
Smith, Omar
Chen, Sara