About This Title

Pages: 356
Published: October 2019
ISBN: 9781680502268
In Print

Skill Level Meter

Programming Phoenix 1.4

Productive |> Reliable |> Fast

by Chris McCord, Bruce Tate and José Valim

Don’t accept the compromise between fast and beautiful: you can have it all. Phoenix creator Chris McCord, Elixir creator José Valim, and award-winning author Bruce Tate walk you through building an application that’s fast and reliable. At every step, you’ll learn from the Phoenix creators not just what to do, but why. Packed with insider insights and completely updated for Phoenix 1.4, this definitive guide will be your constant companion in your journey from Phoenix novice to expert as you build the next generation of web applications.

If you’re new to Phoenix or looking for the most updated information we recommend our Programming Phoenix LiveView book.

eBook Formats:

  • PDF for desktop/tablets

  • epub for Apple Books, e-readers

  • mobi for Kindle readers

Get all eBook formats here for $31.95 (USD)

Add to Cart we accept visa, mastercard, amex, discover, paypal


Paperback Formats:

Please support indie bookstores!
Find indie bookstores in the U.S. Find indie bookstores around the world.


Phoenix is the long-awaited web framework based on Elixir, the highly concurrent language that combines a beautiful syntax with rich metaprogramming. The best way to learn Phoenix is to code, and you’ll get to attack some interesting problems. Start working with controllers, views, and templates within the first few pages. Build an in-memory context, and then back it with an Ecto database layer, complete with changesets and constraints that keep readers informed and your database integrity intact. Craft your own interactive application based on the channels API for the real-time applications that this ecosystem made famous. Write your own authentication plugs, and use the OTP layer for supervised services. Organize code with modular umbrella projects.

This edition is fully updated for Phoenix 1.4, with a new section on using Channel Presence to find out who’s connected, even on a distributed application. Use the new generators and the new ExUnit features to organize tests and make Ecto tests concurrent.

This is a book by developers and for developers, and we know how to help you ramp up quickly. Any book can tell you what to do. When you’ve finished this one, you’ll also know why to do it.

What You Need

To work through this book, you will need a computer capable of running Erlang 18 or higher, Elixir 1.5 or higher, and Phoenix 1.4 or higher. A rudimentary knowledge of Elixir is also highly recommended.

Resources

Releases:

  • P1.0 2019/10/08
  • P1.0 2019/10/08
  • B10.0 2019/09/17
  • B9.0 2019/07/24

Contents & Extracts

  • Preface
  • Introduction
  • Building with Functional MVC
    • The Lay of the Land
      • Simple Functions
      • Installing Your Development Environment
      • Creating a Throwaway Project
      • Building a Feature excerpt
      • Going Deeper: The Request Pipeline
      • Wrapping Up
    • Controllers
      • Understanding Controllers
      • Building a Controller
      • Coding Views
      • Using Helpers
      • Showing a User
      • Wrapping Up
    • Ecto and Changesets
      • Understanding Ecto
      • Defining the User Schema and Migration
      • Using the Repository to Add Data
      • Building Forms
      • Creating Resources
      • Wrapping Up
    • Authenticating Users
      • Preparing for Authentication
      • Managing Registration Changesets
      • Creating Users
      • The Anatomy of a Plug excerpt
      • Writing an Authentication Plug
      • Implementing Login and Logout
      • Presenting User Account Links
      • Wrapping Up
    • Generators and Relationships
      • Using Generators
      • Building Relationships
      • Managing Related Data
      • In-context Relationships
      • Wrapping Up
    • Ecto Queries and Constraints excerpt
      • Seeding and Associating Categories
      • Diving Deeper into Ecto Queries
      • Constraints
      • Wrapping Up
    • Testing MVC
      • Understanding ExUnit
      • Testing Contexts
      • Using Ecto Sandbox for Test Isolation and Concurrency
      • Integration Tests
      • Unit-Testing Plugs
      • Testing Views and Templates
      • Wrapping Up
  • Writing Interactive and Maintainable Applications
    • Watching Videos
      • Watching Videos
      • Adding JavaScript
      • Creating Slugs
      • Wrapping Up
    • Using Channels
      • The Channel
      • Phoenix Clients with ES6
      • Preparing Our Server for the Channel
      • Creating the Channel
      • Sending and Receiving Events
      • Socket Authentication
      • Persisting Annotations
      • Handling Disconnects
      • Tracking Presence on a Channel
      • Wrapping Up
    • Observer and Umbrellas
      • Introspecting Applications with Observer
      • Using Umbrellas
      • Extracting Rumbl and RumblWeb
      • Wrapping Up
    • OTP
      • Managing State with Processes
      • Building GenServers for OTP
      • Designing an Information System with OTP
      • Building the Wolfram Info System
      • Integrating OTP Services with Channels
      • Wrapping Up
    • Testing Channels and OTP
      • Testing the Information System
      • Isolating Wolfram
      • Adding Tests to Channels
      • Authenticating a Test Socket
      • Communicating with a Test Channel
      • Wrapping Up
    • What’s Next?
      • Other Interesting Features
      • Phoenix LiveView
      • Phoenix PubSub 2.0
      • Phoenix and Telemetry Integration
      • Good Luck!

Author

This is the team that drove the implementation of Elixir and Phoenix. Chris McCord, the creator of Phoenix, professionally trains new developers for the rising framework and works with teams adapting it. Bruce Tate, the author of many award-winning books and creator of the Seven Languages in Seven Weeks series, is the founder of Groxio, which is already running Phoenix in production. José Valim, the creator of Elixir and member of the Phoenix core team, is the co-founder and director of research and development at Plataformatec.

eBook Formats:

  • PDF for desktop/tablets

  • epub for Apple Books, e-readers

  • mobi for Kindle readers

Get all eBook formats here for $31.95 (USD)

Add to Cart we accept visa, mastercard, amex, discover, paypal


Paperback Formats:

Please support indie bookstores!
Find indie bookstores in the U.S. Find indie bookstores around the world.

Related Titles:

Skill Level Meter

About This Title

Pages: 356
Published: October 2019
ISBN: 9781680502268
Edition: 1
In Print