Live data from Hacker News

Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

schneider.dev

31–40 of 155 posts

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#31

Why is Elixir always being paired with Phoenix? Can’t I just have a backend API running on Elixir and a javascript front end to interact with it? I’d prefer a simple React, Postgres, Elixir stack (REP).

Because Phoenix is the web framework for Elixir. It's easier to just use phx instead of rolling your own solution around Plug / Cowboy.

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#32
Hey folks! Co-Author of Absinthe here, happy to answer any questions about it. The post here is good, although these days we recommend using Dataloader vs Absinthe.Ecto. Dataloader really extends the idea behind Absinthe.Ecto while providing in request caching, pluggable backends, and easier query manipulation.

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#33

Hey folks! Co-Author of Absinthe here, happy to answer any questions about it. The post here is good, although these days we recommend using Dataloader vs Absinthe.Ecto. Dataloader really extends the idea behind Absinthe.Ecto while providing in request caching, pluggable backends, and easier query manipulation.

Good to know, thanks! I wasn't familiar with Dataloader, I'll have to check it out :)

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#34

Earlier quoted context omitted.

It's 100% the syntax. It appeals to ruby devs and also I think it's a lot easier to grok in general. But you can write Erlang code directly in an Elixir file, you can use Erlang libraries directly in Elixir, and Elixir compiles to the same BEAM instructions that Erlang does, so there's functionally no difference in terms of capabilities or what happens when they run.

This is not totally true. It’s not 100% syntax. Elixir has one additional and widely used feature: macros. In Elixir, as in Lisp, you can transform your code as a data structure into new code. This is importantly used in Ecto, the de-facto object data mapper in Elixir. It’s also used in Absinthe, a library from the posted link for making GraphQL APIs.

Yeah, this is fair. I was mentally lumping certain language features under "syntax" but that's not really accurate.

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#35

Does anyone here who is working with elixir professionally have a sense of what kind of mastery is needed to jump into an elixir dev role? I've used it on and off for ~4 years at this point and in a few side projects (most recent one using everything in the title, weirdly enough) but can't really tell if I'm "qualified" to look for a job in it. It's this weird loop of "I've only done something as a hobby so I'm not q…

> "I've only done something as a hobby so I'm not qualified to do it professionally"

Definitely don't let this hold you back. As long as you're up front about where you are, and are willing to learn, lack of professional experience with a particular language is by no means a deal breaker.

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#37

Why is Elixir always being paired with Phoenix? Can’t I just have a backend API running on Elixir and a javascript front end to interact with it? I’d prefer a simple React, Postgres, Elixir stack (REP).

Yep! Just use Plug. There’s no need to drag the entire Phoenix stack in.

https://hexdocs.pm/plug/readme.html

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#38

Elixir and OTP are really nice, but I'm frustrated by the type system, even with typespecs. I finally gave in and started learning Haskell. I would still choose Elixir/Phoenix for some web apps though.

Have you checked out Gleam?

https://gleam.run

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#39

Ok, for backend, I’m deciding between rust with actix, jvm (kotlin + akka/quasar) or elixir. I kinda know the theoretical differences but I’m curious what hn thinks. Has someone actually deployed things in some of these. I do have preference towards rust but maybe there’s something better.

Fwiw we’ve had a lot of success with Golang (graph-gophers/graphql-go w/ dataloader). Running in prod for about a year. Worth noting is that any GQL server implementation not written in JS, will play catch-up to the JS/Apollo counterpart. The JS ecosystem just moves so much faster

Before having success with Go, did you try or consider any other languages for your GraphQL server? What about other GraphQL libraries in Go?

Re: Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo

#40

Does anyone here who is working with elixir professionally have a sense of what kind of mastery is needed to jump into an elixir dev role? I've used it on and off for ~4 years at this point and in a few side projects (most recent one using everything in the title, weirdly enough) but can't really tell if I'm "qualified" to look for a job in it. It's this weird loop of "I've only done something as a hobby so I'm not q…

Smart teams hire great engineers and trust them to get good with the stack at hand. Don't get hung up on how much experience you have with a particular stack when looking for jobs.

I've hired Rails developers for Django roles and seen them get productive within weeks.

If you've used Elixir on-and-off for four years you have more experience than the majority of engineers who might be considered for an Elixir role.

Post reply on HN