Skip to content
0:00 / 0:00

#elixir#phoenix#liveview

Budget Model & LiveView Forms: Phoenix App from Scratch, Episode 1

Code and Stuff

6.6K subscribers • 20 videos on Hallway

YouTube
  • Recommended by 1 person: 1 in engineering communities.
  • Linked in the descriptionChristianAlexander/tutorial-budget-app
  • May be out of date. The tools, versions or practices it shows have likely moved on.

Beginner. No background in the topic needed.

10K views1 year ago1 recommendation

Web developmentProgramming languagesElixir and ErlangVue, Svelte, Angular and others

This tutorial demonstrates how to create a budget schema, manage contexts, and build interactive LiveView forms in Phoenix.

[series] Build a complete budget tracking app in Phoenix LiveView! In this episode, we'll: - Create our first domain model with the Budget schema - Set up a tracking context to manage budgets - Build a LiveView-powered budget list - Create an interactive modal form - Add user-specific data scoping - Write a few tests This episode introduces LiveView, Phoenix's real-time UI framework, showing how it enables rich interactivity without writing JavaScript. We'll see how Phoenix contexts help organize domain logic, and how to properly scope data to ensure user data doesn't leak to other users. Perfect for developers who want to see how the pieces of a Phoenix application fit together in practice. You'll learn essential patterns like: - Using changesets for validation - Working with database constraints - Preloading associations - Testing LiveView components All code available on GitHub. Links Screen recording software I use (affiliate): screen.studio/@Yy75o Project repo: github.com/ChristianAlexander/tutorial-budget-app Changes from this video: github.com/ChristianAlexander/tutorial-budget-app/pull/3 Additional work and tests: github.com/ChristianAlexander/tutorial-budget-app/pull/4 Timestamps What are we doing? - Create schema - Context module - Test the context - Handling database constraint violations - List and get functions - Budget list UI - Make it a table - Preloading associated data - Testing fixtures - Testing the LiveView - open_browser in Tests - Create budget form - Registering and rendering the form - Add the callback handlers - Test the create form - HTML encoding in tests - Back to the test - Scoping resources to the user - Summary -

Why it's here

1 person recommends this

What people say. Recommended as a step-by-step guide to mastering Phoenix LiveView forms and data scoping.

u/GiraffeFireAlchemistin r/elixir • Recommends

Phoenix App from Scratch: Budget Model & LiveView Forms (Episode 1)