Aporro

Aporro

Seeking help with elixir development environment and absinthe subscriptions

Hi everyone,

I’m reaching out today for some guidance on setting up an Elixir development environment with an effective linter. I’m a university student trying out my hand on a side project that involves full-stack development, and I was particularly interested in exploring Elixir due to its potential for high concurrency, GraphQL subscriptions through Absinthe, and a light introduction to functional programming.

Initially, I was drawn to the Phoenix framework with its channel support for websockets and Absinthe for GraphQL. However, I’ve encountered some challenges in setting up the environment and getting started with Absinthe subscriptions.

Here’s what I’ve tried so far:

  • IDEs: Since I’m a JetBrains IDE user, I initially looked for a linter but the biggest elixir linter people suggested didnt (to my knowledge still doesnt) have support for the 2024 versions of the ides.
  • VS Code: I switched to VS Code with the Elixir Language Server extension. However, it warned me about potential bugs with Erlang 26 on Windows, and subsequent troubleshooting attempts weren’t successful.
  • Dev Containers: I explored using Dev Containers with GitHub Codespaces, but unfortunately, encountered different but similar issues (something about the elixir command not being found) which I also failed to debug
  • WSL Setup: Finally, I managed to set up a development environment within WSL, and while the linter seems to work for basic syntax errors, it doesn’t provide more comprehensive assistance like reference checking for non-existent modules or function signature validation. This lack of advanced features significantly impacts development speed for a newcomer to the language (i was also concernend to see code compiling just fine while referencing modules that dont exist, not sure if thats a quirk of the launguage).
  • Absinthe Subscriptions: Additionally, I struggled to achieve a minimum working example of Absinthe subscriptions using the provided documentation with the GitHub repository demo seeming dated (7 years), I understand that tutorials might also require some updates.

I understand that there might be a learning curve involved, and I’m more than willing to put in the work. However, I’ve never encountered such a frustrating setup process with any other development environment or launguage, i may be spoiled but i am used to this kind of tooling just working.

Truth is I am convinced it’s my fault, it just has to be since everything I’ve heard is about how newbie friendly and productive elixir is and how good the developer experience is and i genuinely wish someone is able to show me what horrible mistake I’ve made to go from that to this

My Questions:

  • Would anyone be willing to share their Elixir development environment setup that offers as much tooling as possible and how to set it up?
  • Are there any up to date resources or tutorials demonstrating how to implement Absinthe subscriptions or a working demo of some kind i can pick apart?

Any guidance or insights you can provide would be tremendously helpful because I am genuinely out of ideas!

Thank you,

First Post!

jmnda

jmnda

Hi, sorry that you didn’t get any response. I will try to answer some of the questions:

IDEs I would recommend VS Code, then install both the elixir-tools and Elixir LS extensions for better language server experience.

Dev Containers: There is a template configuration HERE for an Elixir Dev container environment with Phoenix, Node and PostgreSQL installed, which you could use and customize to your liking.

Absinthe Subscriptions: The only resource that comes to mind is this course by Pragmatic Studio. The course does have you might be looking for, although it’s paid. There also the book Craft GraphQL APIs in Elixir with Absinthe.

Where Next?

Popular in Questions Top

vegabook
I’m brand new to Phoenix and I have stripped one of the demo applications to the bone. I just want to get an svg up on the screen. Here i...
New
RisingFromAshes
I’ve read in another post that it may be possible with a router helper - but I couldn’t find an appropriate one, and tbh, I’m still just ...
New
New
ovidiubadita
Hey all, I discovered Elixir and I love it. I always wanted to learn a functional programming and I intended to go for Haskell, but afte...
New
pmjoe
I have a relationship of love and hate with Elixir. Lots of things are just absolutely right, but there are some things that are kind of ...
New
marius95
Hello everyone, I try to use an Javascript Event Handler in my root.html.leex file. Therefore I created a function in the app.js file: ...
New
fayddelight
I tried installing elixir 1.11.2 erlang 23.3.4 via asdf in my zsh shell. Enabled the versions locally and globally. When I list them ...
New

Other popular topics Top

hariharasudhan94
I would like to know what is the best IDE for elixir development?
New
gshaw
What is the idiomatic way of matching for not nil in Elixir? E.g., First way: defp halt_if_not_signed_in(conn, signed_in_account) when...
New
AstonJ
Seen any cool LiveView demos, sample apps or examples? Please post them here! :003:
New
TunkShif
This post is an instruction guide to help you setup your Neovim for Elixir development from scratch. It includes general information on h...
274 42716 114
New
sergio
Kind of like when jquery came out, it was super necessary. Existing drag and drop libraries have a bunch of baggage to support old browse...
New
senggen
Erlang/OTP 25 [erts-13.2.2] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] 15:22:35.803 [error] gen_event {lager_file_backend...
New

We're in Beta

About us Mission Statement