5Sigma

Adjusting the Layouts

The Phoenix Generator created two layouts for us: * layouts/root.html.heex - The Root Layout is always used. It's a good idea to keep this minimal, since it will apply to all pages. * layouts/app.html.heex - The application layout is used for all LiveViews. The

The Landing Page

We need to cleanup some of the generated code. We can replace the default Phoenix home page, templates, and clean up the filenames. Renaming the Generated Files A PageController controller module, and its associated view have been generated. These can be renamed to function as our landing controller. From the

Character Creation

We have a basic server, and basic user/session management. Now players need the ability to create characters. The Character Model We can use an Ecto generator to build us a database model and migration for the Character entity. From the web app apps/elixir_mud_web run: mix phx.

User Authentication

If we are going to have users, users need authentication. Luckily Phoenix comes with a nice generator for implementing basic authentication. It makes a good starting point: cd apps/elixir_mud_web mix phx.gen.auth Accounts Player players ℹ️If your familiar with the auth generator skip to the

Basic Application Setup

In the beginning there was darkness. App Generation Let’s kick things off by using a Phoenix umbrella application as our trusty scaffold. We’re aiming to build three distinct Elixir applications under this umbrella: * The ‘Phoenix’ application – for the slick web frontend. * A ‘core’ application – responsible for all database

5Sigma © 2026