1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00
v/examples/templates
2021-02-19 17:29:35 +02:00
..
data.json
readme.md
result.md
template.md
templates.v examples: make examples/templates/templates.v runable from everywhere, not just . 2021-02-19 17:29:35 +02:00

example how to work with templates

  • templates support
    • if
    • for loops
    • even nesting of for loops
    • syntax checking
    • embed the template into the binary

Its a very cool way how to do also do e.g. system administration, fill in config files, etc...

The example there is also a good demonstration of how to use json on a more complex object and read/write to file.