We're getting into the good parts of building with Elixir. From data transformation to connecting to outside systems
Show NotesCovering the basics
- Elixir has truthy and falsy Boolean conditionals. I feel right at home
- Variable assignment can only happen on the left side of the equal
For a match to succeed, the LHS and RHS must have the same shape, and each value on the right must match the corresponding value on the left. If the thing on the left is an unbound variable, Elixir binds that variable to the value being matched.
- The LHS cannot contain any calculations or function calls
- Using _ for ignoring values. Helpful in getting a RHS and LHS match
- All variables on the LHS of a match are unbound before the match is made.
- Solution is to use the pin up arrow, *^ to prefix the variable
- users should only see their posts.
- all posts will show on the home page