web / lib/globals/branding-hooks
lib/globals/branding-hooks
Hooks for the Branding global.
Handles automatic favicon generation when favicon source images change. Uses Sharp for image processing (already configured in Payload).
Variables
generateFaviconsHook
constgenerateFaviconsHook:GlobalAfterChangeHook
Generates favicon files when faviconSourceLight or faviconSourceDark changes.
Output files for each theme:
- favicon-light.ico / favicon-dark.ico (32x32)
- apple-touch-icon.png / apple-touch-icon-dark.png (180x180)
- icon-192.png / icon-192-dark.png (192x192)
- icon-512.png / icon-512-dark.png (512x512)
Last updated on