template

package
v0.1.149 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 23, 2026 License: MIT Imports: 0 Imported by: 0

Documentation

Overview

Package template provides pure functions for building template data maps.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddAuthToData

func AddAuthToData(data map[string]any, isAuthenticated bool) map[string]any

AddAuthToData adds authentication state to a template data map. If data is nil, a new map is created. Returns the modified map.

func AddCSRFToData

func AddCSRFToData(data map[string]any, csrfToken string) map[string]any

AddCSRFToData adds CSRF token to a template data map. If data is nil, a new map is created. Returns the modified map.

func AddCommonData

func AddCommonData(data map[string]any, isAuthenticated bool, csrfToken string) map[string]any

AddCommonData adds both authentication state and CSRF token to a template data map. If data is nil, a new map is created. Returns the modified map.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL