Absinthe for Large Elixir Applications
Discover how you can best use Absinthe for data-heavy Elixir applications: https://blog.appsignal.com/2023/06/06/absinthe-for-large-elixir-applications.html
Migrating from pow to phx.gen.auth
How to migrate from the pow library for authentication to phx.gen.auth without breaking anything for users. https://2metz.fr/blog/migrate-from-pow-to-phx-gen-auth/
Migrating to Verified Routes
Verified Routes are an exciting feature introduced in Phoenix in v1.7. For those of us with a mature project, we may have already upgraded to Phoenix v1.7, but we didn’t stop to migrate the hundreds of routes in our project. Now that some time has passed, we are ready to bring the benefits of simpler, clearer routes that are compile-time checked to our project. Perhaps the plan was to slowly convert our routes over time. But what if we could get it all done today? In this post, we use a community created custom mix task to migrate the bulk or the routes and we cover how to clean-up what’s left over. Get the benefit of Verified Routes now!
Unit testing SQL functions in an Elixir project
If you ever needed to add an SQL function that you can use in your Elixir project you might have skipped writing tests for it. There are a couple of official ways1 2 you can write unit tests for PostgreSQL functions but having it in the same code base will make it so you actually maintain the tests.
Testing LiveView course is completely updated with Phoenix 1.7 and LiveView 0.18!
My Testing LiveView course is completely updated with Phoenix 1.7 and LiveView 0.18! (and soon with 0.19)
I rebuilt it from the ground up to make it utterly practical.
Each lesson is short and to the point, crafted from my experience testing LiveView apps in the wild, and refined by my ten years of practicing TDD.
If you’re looking for a great way to learn how to test LiveView apps, give it a look!. 👇
Context maintainability & guidelines in Elixir & Phoenix
The concept of Phoenix Context may appear straightforward, yet its potential for significantly boosting Phoenix app maintainability is profound. However, the truth is many developers grapple with its effective implementation.
In this blog post, I unveil a strategic solution for optimizing context organization, a critical step towards sustainable and efficient Phoenix app development.
https://curiosum.com/blog/elixir-phoenix-context-maintainability-guildelines
ThinkingElixir 153: Elixir Tools and Language Servers
Episode 153 of Thinking Elixir. Language servers are an important part of modern developer tooling. Mitch Hanberg has made this his new focus with gen_lsp, a generic language server behaviour that he then implemented a Credo language server on top of. Yes, that’s right, Credo! We learn what that means and what his new elixir-tools Github organization is intended to do. Listen to Mich share his vision for what Elixir dev tools could be like! We get an update on his Temple project, an alternative to Phoenix templates, we learn about an existing Elixir formatter plugin that may reformat code more to your liking and more!
You should go to ElixirConf!
Made a video about my experience at ElixirConf EU in Lisbon. If you are curious about going to a community event like this, I hope this video helps your thinking along:
I had a lovely time. Thanks to everyone who contributed to that.
Pogo - distributed supervisor for Elixir
Pogo is a distributed supervisor built on top of Erlang process groups. It abstracts away the complexity process scheduling and supervision in distributed environment. https://szajbus.dev/elixir/2023/05/22/pogo-distributed-supervisor-for-elixir.html
Recompile your code from within IEx
I’ve seen people quit out of IEx and restart it to load new changes to their code.
No need for that! Here are some cool helpers for you 👇
- recompile/0 will recompile your whole project
- r/1 will reload and recompile a single module
See it in action 👉 https://youtube.com/shorts/L52bYdfwwe8 👀
Super simple guide to Livebook
Improve your productivity in Elixir with LiveBook. This tool allows you to collaborate and experiment on interactive code notebooks.
Editing forms with live_file_input
Ever tried to use live_file_input in a form and edit the previously uploaded files? I did and learned some things. Check here
https://blog.miguelcoba.com/editing-forms-with-live-file-input
ThinkingElixir 152: Rust and Elixir Play Great Together
Episode 152 of Thinking Elixir. Rust is a popular lower level language and the community has created a number of libraries to solve different problems. We talk with Jason Stiebs, a Phoenix Core Team member, about how Elixir and Rust can play well together. Jason wrote an article about how he leveraged an image processing library available in Rust by using the Elixir Rustler package. We talk about how Rustler works through NIFs, and we learn how easy using Rustler has become. It’s great to understand that we have a powerful escape hatch like Rustler for those times we need it. We also get Jason’s insights into the Phoenix project and talk about the importance of improving the developer experience when a LiveView crashes and more!
Tackling Performance Issues in Ecto Applications
Let’s dive into three common performance issues in Ecto applications and see how to fix them: https://blog.appsignal.com/2023/05/23/tackling-performance-issues-in-ecto-applications.html
Leveling up your Elixir codebase with types
Types in Elixir, while not mandatory, can greatly improve your code base and developer experience while simultaneously preventing the project from falling into the “legacy” space. https://medium.com/wttj-tech/leveling-up-your-elixir-codebase-with-types-795bd17d4d70
Experimenting with graph databases with Memgraph and Elixir
I had a conversation with Marko Budiselić, the CTO at Memgraph, during this year’s DORS/CLUC conference. We discussed graph databases in detail and explored their capabilities and applications. Since I had no prior experience with graph databases, I found the discussion fascinating. As an enthusiastic user of Elixir, I was especially curious about the possibility of integrating Elixir with Memgraph and using its features within the Elixir ecosystem.
The idea of this post is to experiment with Memgraph and see (1) if we can use it with Elixir at all, and (2) how it all works under the hood. As of the time of writing this I haven’t found any tutorials or guides on how to use it with Elixir, and we obviously need to fix that ASAP 😀.
Loading a structure.sql File on Prod Without Mix
Have you run mix ecto.dump
and now rely on a structure.sql
file to bootstrap a new DB? When you deploy a release to a production-like environment, you don’t have MIX and you can’t run mix ecto.load
. See how we can still bootstrap a clean staging environment or deploy to a fresh prod DB! (Spoiler: We’ll steal code from ecto_sql!)
https://fly.io/phoenix-files/loading-structure-sql-on-prod-without-mix/
Adoption of Elixir in production by top companies
Discover our new publication about using Elixir in production in companies such as Stord, Allegro Lokalnie, V7, Multiverse.io, Remote, Slab, Mozilla Hubs and Heroku.
➡ https://curiosum.com/blog/adoption-of-elixir-by-top-companies
#Elixir #elixirinproduction