proxy.golang.org : github.com/janpfeifer/monitored-templates
Package montemplates parses HTML templates from a file tree and optionally monitors for changes. During construction, it parses all the templates under a root directory, traversing subdirectories for files with the given patterns. At execution time, if `dynamic` is set to true, at every request (`Get()` method) it checks whether files have changed, and re-parses them accordingly. This is very useful during development, but you want to turn it off during production because of the cost of checking whether the files changed in the filesystem. If `dynamic==true` it does proper serialization (`sync.Mutex`) to prevent concurrency conflicts. If `dynamic==false` it is read-only and there is no contention. ## Example
Registry
-
Source
- Documentation
- JSON
- codemeta.json
purl: pkg:golang/github.com/janpfeifer/monitored-templates
License: Apache-2.0
Latest release: almost 2 years ago
First release: almost 2 years ago
Namespace: github.com/janpfeifer
Last synced: 7 days ago