You should have Elm return the <ul>, and embed the program an empty div. I
am pretty sure you are only allowed to embed Elm programs in divs anyway,
not just any old html tag.
On Wednesday, March 22, 2017 at 7:36:44 AM UTC-7, Matt Joiner wrote:
>
> I'm looking to embed Elm in an existing web application gradually. I find
> it most appropriate in my projects to embed multiple elements, not a single
> parent element. For example I have some bootstrap:
>
> <ul class="dropdown-menu" id="some-list"></ul>
>
> I want to run Elm.Main.embed(document.getElementById('some-list')), and
> have that main return multiple <li> elements. Clearly I can't have Elm
> return a parent <ul> because then I have <ul><ul></ul></ul>. I also can't
> have Elm return the <ul class="dropdown-menu" id="some-list"></ul> because
> then there's no #some-list to embed it on in the first place.
>
> Look forward to suggestions, thanks.
>
--
You received this message because you are subscribed to the Google Groups "Elm
Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.