HTML Element

Create an HTML element managed by Elm. The resulting elements are easy to embed in larger JavaScript projects, and lots of companies that use Elm started with this approach! Try it out on something small. If it works, great, do more! If not, revert, no big deal. page Unlike a sandbox, an element can talk to the outside world in a couple ways: * Cmd — you can “command” the Elm runtime to do stuff, like HTTP. * Sub — you can “subscribe” to event sources, like clock ticks. * flags — JavaScript can pass in data when starting the Elm program * ports — set up a client-server relationship with JavaScript

As you read the guide site you will run into a bunch of examples of element in this section page . You can learn more about flags and ports in the interop section page .