Deprecated
Superseded by mix cms_gen.support_widget, which does everything this does
(report an issue) plus live chat, over one deploy-key socket connection
instead of OAuth/REST. Prefer the support widget for new apps; this
feedback-only widget remains only for existing installs.
Generates a floating feedback widget that reports issues to CodeMySpec.
$ mix cms_gen.feedback_widget
This generator requires cms_gen.integrations to have been run first.
Generated files
lib/app_web/live/feedback_widget.ex— LiveComponent (self-contained, checks own auth)lib/app/codemyspec/client.ex— HTTP client for CodeMySpec APIassets/js/screenshot.js— Screenshot capture via html-to-image
How it works
The widget is a LiveComponent that checks its own connection status. If the user hasn't connected to CodeMySpec, it renders nothing. No on_mount hooks, no prop-drilling, no layout attr changes needed. Just add it to Layouts.app — current_scope is already passed there.
Prerequisites
- Run
mix cms_gen.integrationsfirst - Run
mix cms_gen.integration_provider CodeMySpec codemyspec