Open Light-Wizzard opened 6 years ago
That's a good point - a dynamic menu package would be a nice additional. You can create your own template functions in Blue Jay:
https://blue-jay.github.io/views/#view-functions
You can write a function that generates the menu in Go so you don't have to define it in your templates.
Feature request:
go env
)? Arch Linux Manjaro, GOHOSTOS="linux", GOHOSTARCH="amd64", go version go1.10.3 linux/amd64Dynamic Menu and Content Maintaining a Static Site is hard to do, there should be a way to Dynamically add Menu items and Content.
In the Controller.go LoadRoutes, it would be easy enough to iterate through the database for dynamic menu items, and store a template name and content in database entry for menu item and store a static template in a Dynamic Menu Folder, I know this would be a major change, but one everyone would agree with, Dynamic and Static should mix well. I have just started to use this framework so I am not yet fully familiar with the code enough to make the changes, so I thought I would suggest it and see what your thoughts are, and to see if this issue has already be addressed.
Update: Grant you I can make this Dynamic in my Front End as it is, but its not Database Driven, and it seems that might be faster, but only benchmarks would determine. Static pages cache better so maybe you can ignore this request if that is the case.