What's the possibility of creating a “drop-in component” (React-like) using LiveView?

With Phoenix/Elixir generating the template and session, you can request the initial rendered page with jQuery or similar, then connect to the remote socket with a callback. Something like the following on another web server:

import { LiveSocket } from "phoenix_live_view"

let liveSocket = new LiveSocket("ws://localhost:4000/live");

$(document).ready(() => {
  $("#thermostat").load("http://localhost:4000/thermostat", liveSocket.connect);
});

There may be a better way to go about this, but this works if you just need to embed a LiveView component once onto an existing page.