Skip to content

Latest commit

 

History

History
243 lines (145 loc) · 3.44 KB

slide-deck.md

File metadata and controls

243 lines (145 loc) · 3.44 KB
theme class
uncover
invert

Phoenix LiveView

A Solution to Madness - Joshua Plicque


What We'll Cover

  • What is Phoenix LiveView and what does it promise?
  • How LiveView Works
  • Phoenix LiveView Programming Model - Thinking in LiveView
  • Using Phoenix Contexts to reuse code and quickly spin up API's
  • Writing Tests - And why it's blissful
  • Coding with alpha software

bg







  • I run a small web development shop
  • Developing Software Professionally for 7 years
  • Been using LiveView full-time for just under a year

Phoenix LiveView is an exciting new library which enables rich, real-time user experiences with server-rendered HTML. LiveView powered applications are stateful on the server with bidirectional communication via WebSockets, offering a vastly simplified programming model compared to JavaScript alternatives.


Chris McCord


bg


bg


bg contain bg contain bg contain bg contain


The people demand better



The LiveView Promise

Get blackout drunk with no hangover.





Big

Cojones




How does LiveView work?



How does LiveView work?

  1. Endpoint
  2. Router
  3. Initial Mount
    1. Mount (HTML and Websocket)
    2. handle_params()
    3. render()
  4. Responding to Events
    1. handle_event()
    2. render()

Grossly Overengineered Church Website Demo


Thinking in Model-View-Controller

  1. Endpoint
  2. Router
  3. Controller
    1. Loads data from schema
    2. Supplies data to the view
  4. View
  5. Template

Thinking in LiveView


Thinking Demo - Banner Uploads

  1. Endpoint

Thinking Demo - Banner Uploads

  1. Router

Thinking Demo - Banner Uploads

  1. Initial Load

Thinking Demo - Banner Uploads

  1. Responding to Events

Thinking Demo - Banner Uploads

  1. The Context Layer

Thinking Demo - Banner Uploads

  1. The Schema Layer

Pretty sweet right?


Sounds cool. But you're just a lowly CRUD app developer


BUT WAIT, THERE'S MORE


Quickly Exposing APIs

You can leverage Phoenix's Context layer standard architecture to quickly bolt on API's


bg contain


Let's go back to church. API goodness


Also, testing is lightning fast


LiveView Version 0.15.x????


The documentation is best-in-class. Premium. Free. Just read the docs. It's ALL THERE!!!


Shill


???