mirror of
https://github.com/pantor/inja.git
synced 2026-05-19 02:35:23 +00:00
add logo
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
# Inja
|
||||
[](https://github.com/pantor/inja/releases)
|
||||
|
||||
|
||||
[](https://travis-ci.org/pantor/inja)
|
||||
[](https://coveralls.io/r/pantor/inja)
|
||||
@@ -18,7 +19,7 @@ inja::render("Hello {{ name }}!", data); // "Hello World!"
|
||||
|
||||
## Integration
|
||||
|
||||
Inja is headers only. Just one dependency: json by nlohmann.
|
||||
Inja is headers only. Just one dependency: json by nlohmann.
|
||||
|
||||
```c++
|
||||
#include "json.hpp"
|
||||
@@ -28,7 +29,7 @@ Inja is headers only. Just one dependency: json by nlohmann.
|
||||
using namespace inja;
|
||||
using json = nlohmann::json;
|
||||
```
|
||||
|
||||
|
||||
|
||||
## Tutorial
|
||||
|
||||
@@ -59,7 +60,7 @@ The environment class can be configured.
|
||||
Environment env_default = Environment();
|
||||
|
||||
// With global path to template files
|
||||
Environment env_default = Environment("../path/templates/");
|
||||
Environment env_default = Environment("../path/templates/");
|
||||
```
|
||||
|
||||
### Variables
|
||||
@@ -75,7 +76,7 @@ data["time"]["end"]["hour"] = 21;
|
||||
|
||||
string template = """
|
||||
{{ guests/0 }}
|
||||
|
||||
|
||||
{{ time/start/hour }} to {{ time/end/hour }} or {{ 24 }}
|
||||
""";
|
||||
```
|
||||
@@ -160,6 +161,3 @@ Currently, the following compilers are tested:
|
||||
## License
|
||||
|
||||
The class is licensed under the [MIT License](https://raw.githubusercontent.com/pantor/inja/master/LICENSE).
|
||||
|
||||
|
||||
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 44 KiB |
Reference in New Issue
Block a user