My first ever Elixir line of code has been written here.
I wanted to challenge my self and learn a new language/framework (the basics for start) in less then a week so I choose Elixir and Phoenix LiveView even though I was never in touch with them before. Phoenix LV makes the multiplayer implementatino of the game much easier.
It was a very fun journey btw!
Note: Regarding the multiplayer mode, I have the implementation in my head and I know it would take somebody who know Pheonix LiveView better 20 minutes to write it in this project but I don't have much more time at the moment and it would take me a bit more time. Maybe I will do it later.
Click here to read the project requirements
- Elixir v1.14 - https://elixir-lang.org/install.html
- Default port is http://localhost:4000
- Install dependencies with mix deps.get
- Start Phoenix endpoint with
mix phx.server
or inside IEx withiex -S mix phx.server
Now you can visit localhost:4000
from your browser.
- Read Elixir's Getting started Guide
- Watched Phoenix LiveView Crash Course by James Moore
- Got initial inspiration from https://github.com/drewfravert/2048
- Guides that gave me inspiration for writing concise and easy to read Grid.move() function Elixir comprehension and Kernel.SpecialForms
- As I was getting more familiar with Elixir I learned that I should have using pattern matching much more like I have seen in this implementation of 2048 Game
- DB design and queries for high load LINK
- Palindrome finder algorithm task with unit testing LINK
- File explorer problem (with DB stackoverflow prevention) LINK
I just started one and it's still work in progress and I am happy to share it with you
- Separating Domain and Persistence logic LINK
I have this one amazing contribution to Linear, check it out :D