KP123
1
Using PolymorphicEmbed v4.1.1
I get the error: module PolymorphicEmbed.HTML.Form is not loaded and could not be found
When attempting to import the module as stated in the docs
Has anyone run into and fixed this problem? Is this an issue with the lib or something else in my project?
Originally posted in the Elixir chat but moved here for search and visibility
KP123
3
PhoenixHTMLHelpers.Form is not loaded
Are those modules not loaded automatically by Phoenix? Where would I import them? In my endpoint?
phoenix_html_helpers is listed as an optional dependency for PolymorphicEmbed, so you’ll need to add it to your project’s mix.exs explicitly.
After that, you may need to add it to the lib/whatever_web.ex file in places where use Phoenix.Component happens, for instance:
https://github.com/fly-apps/live_beats/blob/ac9780472e7019af274110a1cf71250a8d40c986/lib/live_beats_web.ex#L36-L38