acrolink

acrolink

Framework similar to Laravel for Elixir?

Except for Phoenix, I mean with commands support, tinker, jobs, scheduler, database modelling with complex relashionship declarations … Tools which make fetching data from DB easier …

Most Liked

dorgan

dorgan

There’s no one-size-fits-all solution in Elixir, you have instead lots of libraries that are highly interoperable.

Web: Phoenix
Commands: I guess you could say mix tasks and release scripts?
Jobs: Oban or Broadway if you use something like SQS
Scheduler: Oban probably, or Quantum, depends on what kind of scheduling you mean
Database modelling with complex relationship declarations: Ecto (included with Phoenix project generators)

Contrary to common beliefs from newcomers to the ecosystem, phoenix is just a web library and nothing more, the rest of the functionality comes from other libraries, and some of the generator options for mix phx.new include them in your project because it’s just so common to use them. Phoenix is not your application so for the most part it will relegate itself to the web layer and get out of the way when designing the core of your system(for which web is just one of the many interfaces you can have).

A note on Ecto though: it’s a library for data modelling, casting/validation, persistence and query builder. It’s NOT an ORM like Eloquent/ActiveRecord, so there’s some getting used to you’ll have to go through, it’s a paradigm shift.

And a honor mention to Ash framework, which can be used together with all the above to reduce boilerplate and make things easier to extend.

11
Post #2
sodapopcan

sodapopcan

@dorgan summed it up nicely but just adding that it looks like tinker would just be iex. In Elixir land, having access to your entire app in a shell isn’t anything special and definitely not framework-secific. Any mix project (Phoenix is a mix project) can be loaded into iex by starting it with -S mix inside your project’s root directory: ~/my_app/$ iex -S mix. Furthermore, any Elixir module can be loaded into a running shell with the c function: iex> c "some_file_containing_a_module.ex"

lud

lud

Tinker is just iex -S mix phx.server, it will launch the app and you will be in the IEx REPL with access to all modules and functions existing in the system. (As in any other non-phoenix elixir app but it would simply be iex -S mix, which will work with phoenix but it will not start the web server by default).

For commands you can create mix tasks, it is not specific to the web framework but supported directly by Mix.

As @dorgan said, while PHP is lacking a lot of developer tools that are then provided by frameworks, a lot of stuff is direclyt available in the language or provided by specialized libraries in the Elixir world.

Where Next?

Popular in Questions Top

LegitStack
I’m hoping you guys can give me some general advice and perhaps code examples if you’re feeling up to it. I’m very interested in Elixir,...
New
Kagamiiiii
Student & New to elixir. Nice language. I want to convert a english character, e.g. “a”, which is stored in a variable, to it’s asci...
New
lastday4you
I wanted to check elixir version in phoenix because i found that my elixir is 1.5 but when i use Enum.chunk_by it said the function is un...
New
mgjohns61585
Could someone help me? I'm making my first elixir program, number guessing game. I can't figure out how to convert the user's guess from ...
New
makeitrein
Hey all, just started picking up Elixir last week and am writing a scraper as a learning project. Baby step #1 is extracting the number ...
New
rms.mrcs
Hi, I need to transform a list of numbers into a map where the keys are the indexes and the values are the original values of the list....
New
alice
Hey, Just curious what are the main benefits of Elixir compared to Clojure? When is Elixir more useful than Clojure and vice versa? Th...
New
qwerescape
Is there a way to get the call stack or stack trace at any point in the code? Not from exceptions, but an expression that returns how the...
New
chrisalley
ExUnit now has describe blocks which is a welcome addition coming from RSpec. In the docs, it states that nested hierarchies of describe ...
New
9mm
I am constructing a JSON object (map) and I need to conditionally set a field. I’m trying to write proper elixir-way code… and I’m at a l...
New

Other popular topics Top

shahryarjb
Hello, I get Persian date from my client and convert it to normal calendar like this: def jalali_string_to_miladi_english_number(persi...
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
sergio
In Ruby, I can go: User.find_by(email: "foobar@email.com").update(email: "hello@email.com") How can I do something similar in Elixir? ...
New
KronicDeth
Elixir plugin for JetBrain’s IntelliJ Platform (including Rubymine) This is a plugin that adds support for Elixir to JetBrains IntelliJ...
289 35421 110
New
mgjohns61585
Could someone help me? I'm making my first elixir program, number guessing game. I can't figure out how to convert the user's guess from ...
New
minhajuddin
I have seen a lot of code which picks the first element from a list using Enum.at(0) instead of List.first. Is there a reason why people ...
New
rms.mrcs
Hi, I need to transform a list of numbers into a map where the keys are the indexes and the values are the original values of the list....
New
baxterw3b
Hi guys, i’m new in the Elixir world, and i have to say, that i love it! i’m having some problem to understand anonymous functions with ...
New
Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID<0.412.0> terminating ** (Postgrex.Error) FATAL...
New
beno
I will often find my self writing things similar to: case some_value do nil -> something() "" -> something() _ -> someth...
New

We're in Beta

About us Mission Statement