Phoenix Framework Cheat Sheet1. Create a New Phoenix Project
2. Configure the Database
Edit config/dev.exs 3. Generate Task Schema
4. Migrate Database
5. Implement Task Context Functions
Define schema "tasks" Add fields: title, description Create changeset function Implement CRUD functions: list, create, update, delete |
6. Implement Task Controller Functions
Use TaskMasterWeb, :controller Alias TaskMaster.Task Define controller actions: index, create, show, update, delete 7. Test the Application
GET /tasks (list tasks) POST /tasks (create task) GET /tasks/:id (view task) PUT /tasks/:id (update task) DELETE /tasks/:id (delete task) |
Cheatography
https://cheatography.com
Elixir functions Cheat Sheet (DRAFT) by liebus
Elixir functions: - Anonymous Functions
This is a draft cheat sheet. It is a work in progress and is not finished yet.