Keksdose.FrontendConfig (keksdose v0.4.1)

Copy Markdown View Source

Helper to inject the ingestion endpoint URL into client HTML.

Render somewhere in your layout <head>:

<%= raw Keksdose.FrontendConfig.inject_script("/api/cookie-consents") %>

The emitted script defines window.keksdoseEndpoint. The host's JS consent library should POST to that URL.

No default endpoint is assumed — the host chooses where to mount the Keksdose.PlugHandler plug via forward and passes that path here.

Summary

Functions

inject_script(endpoint_url)