Phoenix LiveView enables rich, real-time user experiences with server-rendered HTML. For more information, see the initial announcement.
Note: Currently LiveView is under active development and we are focused on getting a stable and solid initial version out. For this reason, we will be accepting only bug reports in the issues tracker for now. We will open the issues tracker for features after the current milestone is ironed out.
As official guides are being developed, see our existing comprehensive docs and examples to get up to speed:
- Phoenix.LiveView docs for Elixir and JavaScript usage
- Phoenix.LiveViewTest for testing docs
- LiveView example repo with a handful of examples from Weather widgets, autocomplete search, and games like Snake or Pacman
There are currently two methods for installing LiveView. For projects that require more stability, it is recommended that you install using the installation guide on HexDocs. If you want to use the latest features, you should follow the instructions given in the markdown file here.
All current Chrome, Safari, Firefox, and MS Edge are supported. IE11 support is available with the following polyfills:
$ npm install --save --prefix assets mdn-polyfills url-search-params-polyfill formdata-polyfill child-replace-with-polyfill classlist-polyfill
// assets/js/app.js
import "mdn-polyfills/CustomEvent"
import "mdn-polyfills/String.prototype.startsWith"
import "mdn-polyfills/Array.from"
import "mdn-polyfills/NodeList.prototype.forEach"
import "mdn-polyfills/Element.prototype.closest"
import "mdn-polyfills/Element.prototype.matches"
import "child-replace-with-polyfill"
import "url-search-params-polyfill"
import "formdata-polyfill"
import "classlist-polyfill"
import {Socket} from "phoenix"
import LiveSocket from "phoenix_live_view"
...