lua-resty-template icon indicating copy to clipboard operation
lua-resty-template copied to clipboard

Templating Engine (HTML) for Lua and OpenResty.

Results 14 lua-resty-template issues
Sort by recently updated
recently updated
newest added

I have a file defining some blocks, such as ``` {-head-} .... {-head-} ``` When I use `template.render("some.html")`, an error occurs: ``` 20xx/xx/xx xx:xx:xx [error] 217324#217324: *10239 open() "/path/to/templates/ .......

bug

Hi, I have a few templates whose output is very long and I think the render() method captures all the output in a string before finally outputting it, which consumes...

Let's say I have this code in template ``` // {# comment #} console.log(name); ``` Which correctly compiles to ``` // console.log(name); ``` But if I enable precompilation of Lua...

hello, bungle, any plan to this?

how to set css file direcotry, when i use the html template? how can i find the path css/bootstrap.min.css in html ?

```lua local template = require "resty.template" local layout = [[ {*blocks.title*} {*view*} {*blocks.title*} {*blocks.title*} ]] local content = [[ {-title-} I'm title {-title-} hello!]] ngx.say(template.new(content, layout):process()) ``` output: ``` hello!...

for http2 request, it's not working. for example: ``` curl --http1.1 https://example.com # works curl https://example.com # default http2 not working ```

``` server { server_name a; set $template_root /etc/nginx/sites/a; location / { content_by_lua_file '/etc/nginx/sites/a/index.lua'; } } server { server_name b; set $template_root /etc/nginx/sites/b; location / { content_by_lua_file '/etc/nginx/sites/b/index.lua'; } } index.lua:...

bug

I've started using this library and I like it. I need a mechanism to support multiple languages (as in i18n/localization). I've done some initial googling but have not found pointers...

Hello. bungle, I notice `view` is not in `Reserved Context Keys and Remarks`. But it does seem a reserved one, for you can use `{*view*}` in a layout file without...