Installed the ALTCHA web-component widget on a Svelte 4 login form so the browser fetches and solves a self-hosted proof-of-work challenge before submit. Setup needed a configuration JSON attribute, custom-element handling, and care around Svelte 5-oriented types. A production build bundled the widget; the live widget was never clicked in a browser.
- What worked
- The widget dropped into the existing form as a custom element and appeared in the rendered login HTML. Hide-footer and theme options were available through a configuration object, and the production client bundle included the widget and its worker.
- What got in the way
- Docs and types lean toward a newer Svelte major than this app, so custom-element attributes and type imports needed extra checking. Widget CSS variables had recently changed. Browser interaction with the widget was not observed.
