xddxdd / bird-lg-go

BIRD looking glass in Go, for better maintainability, easier deployment & smaller memory footprint
GNU General Public License v3.0
141 stars 27 forks source link

Add static file bundling and HTML templating #8

Closed elburb closed 3 years ago

elburb commented 3 years ago

PR opened for initial comments.

This PR goes some way to resolving issue #3 by using bindata to package files in to the frontend binary. This enables moving HTML out of the go code in to templates and for the delivery of static files from the webserver (e.g. for the robots.txt file, bundling dependencies or local customisations such as a logo).

lgtm-com[bot] commented 3 years ago

This pull request introduces 3 alerts and fixes 3 when merging 6179c688be5f0873b0ddc9838e7e458b14e9f439 into 8d0e21057261a51cfd28da96217f523600f38f3b - view on LGTM.com

new alerts:

fixed alerts:

lgtm-com[bot] commented 3 years ago

This pull request introduces 3 alerts and fixes 3 when merging f4b69553435dda55249285bb70d94b0a28a57857 into 8d0e21057261a51cfd28da96217f523600f38f3b - view on LGTM.com

new alerts:

fixed alerts:

xddxdd commented 3 years ago

I tested the template functionality and can confirm that it works. I think this PR is ready for merge.

Please mark the PR as ready if you also think so.

elburb commented 3 years ago

Yup, I'm happy now that it's been battle tested on my site; so good to go.