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

logicmason
Hi there, I'm working through my first release with elixir/phoenix. I've built a release with distillery and found that it crashes when I...
New
joaquinalcerro
Hi there, I am working with Ecto-Postgresql and I need to call all of the records from a specific table but the table has 40,000 record...
New
jerry
Good day to you all. I have been struggling to get a query involving like and ilike to work. Can anyone assist me on this, please? pro...
New
aalberti333
As the title describes, I’m trying to run Enum.map() over a list of key/value pairs, where the value is a map. My data looks like this: ...
New
nsuchy
Hi. I’ve noticed that Windows Powershell has it’s own IEX command and you cannot access Elixir’s IEX due to the conflict. This isn’t a cr...
New
ashish173
I am using Ecto timestamps with postgres, I can see the timestamps() use the :naive_dateime but for my use case I wanted to store the ti...
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
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
LegitStack
I’m trying to make a websocket server in Phoenix or raw Elixir. I heard about gun, I think I could use cowboy, but since I’m not that sma...
New
beno
I will often find my self writing things similar to: case some_value do nil -> something() "" -> something() _ -> someth...
New

Other popular topics Top

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
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
malloryerik
Hi, this is for people who, like me, have had some friction using .html.heex templates in VSCode. The solution seems to be, in a hyphena...
New
polypush135
As many of you may have realized by now (sorry for all the posts here) I’ve been working on a db problem where I’m trying to aggregate a ...
New
lk-geimfari
What is most correct way to open, read and parse JSON file with poison? For example if we have example.json file in root of some projec...
New
chrismccord
As promised, the first release candidate of Phoenix 1.3.0 is out! This release focuses on code generators with improved project structure...
New
mcarvalho
What is the difference between System.get_env and Application.get_env? For example, what are best practices to use one versus another.
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
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
Fl4m3Ph03n1x
About me? ( if you have nothing better to do than reading about some random guy in the internet :stuck_out_tongue: ) Hello all, this is ...
New

We're in Beta

About us Mission Statement