HUGO
Menu
GitHub 90466 stars Mastodon

hugo.IsProduction

Reports whether the current running environment is “production”.
Syntax
hugo.IsProduction
Returns
bool

Usage

The hugo.IsProduction function reports whether the current running environment is production, the default when you run the hugo build command. Use the hugo.Environment function to return the name of the current running environment.

Examples

{{ hugo.IsProduction }} → true/false