AstonJ

AstonJ

I’m not sure about anyone else, but I’ve been more than content with the promise of Phoenix; a fast, highly scalable and productive (i.e. enjoyable!) web framework. So I haven’t really been thinking about a Phoenix wish-list since it’s already giving me what I wanted.

LiveView changed that! :upside_down_face:

So that got me thinking - what else is there that we might love to be in Phoenix - no matter how big of a leap or a dream it might be :upside_down_face:

Showing Posts 1 to 10

AstonJ

AstonJ OP

For me, so far Phoenix ticks two of the boxes (speed/scalability, and soon, making front end easier thanks to LiveView) and the only other thing that would make me even more ecstatic is… doing something similar for Mobile! Imagine if we could create native mobile apps (even if just via their web view - like some of the current Mobile frameworks) as easily as what LiveView is going to enable us to do for web apps? How cool would that be? :007:

Wonder if we all chip in and buy Chris a pack of these each it might actually happen? :003:

https://twitter.com/chris_mccord/status/1039190145927454720

dimitarvp

dimitarvp

I think you nailed the two near-future aspects:

  1. Making a perfect blend between Drab, LiveView and Phoenix semantics. It’s really not surprising that frameworks like Drab exist; frontend is a nightmare environment due to JS flakiness (a huge topic in itself) and eventually people just go like “screw this, let’s do something close enough that’s much more maintainable and productive!”. I am so glad LiveView got introduced.
  2. Starting to aim for mobile. IMO that’s a huge challenge on all platforms and languages. Go is trying and so far they have some success but for our branch to succeed we need a full-blown BEAM working on Snapdragon and Exynos chipsets, and iDevices. Not sure how hard that is, probably a lot. Not to mention that both Android and iOS development isn’t exactly perfectly streamlined (although tools are improving regularly). Bonus points for actual Kotlin and Swift bindings to make the two-way interaction between Android/iOS and the BEAM inside the mobile ecosystem easier.

What I would like to see in Phoenix next would be something a bit more academic: state machines. For example, I already coded orders, carts, line items, fulfillment etc. e-commerce details in PHP, Ruby and Elixir about 12-13 times in the last 5 years already. And the truth is, a rather straight-forward (if a bit hard to express and code initially) state machine would have eliminated most bugs right from the get go. No small amount of real-world abstractions can be coded with state machines. Of course, the trouble comes when you have to ask the question: “alright this is so well working and abstracted now but what about special cases X, Y and Z?” – and there’s always something like that happening. Not sure I have a good solution for that yet.

yurko

yurko

why would you want it in Phoenix? Erlang has it so we can use it right now gen_statem — OTP 29.0.2 (stdlib 8.0.1) but all in all imo it’s somewhat low level for a web framework.

dimitarvp

dimitarvp

Exactly because of what you said – it’s low level and if we have more first-class-citizen support that would help us reduce bugs.

But it’s mostly just a desire without me giving it much thought yet. Elixir is pretty good at making DSLs so I imagine that would be the easy part. How would that integrate with the rest of Phoenix and not confuse people however, would definitely be much more challenging.

kokolegorille

kokolegorille

As a side note there is an Elixir wrapper for gen_statem.

https://github.com/ericentin/gen_state_machine

yurko

yurko

Well wouldn’t it make sense to just use the Erlang’s one “under the hood” in the services that need it and expose the public API for Phoenix related parts (channels, controllers etc.)? :slight_smile:

dimitarvp

dimitarvp

As of today, yes, of course it does. This still entails the mandatory steps of you devising a flow using REST / GraphQL / something-else which will utilize the state machine under the hood. My point here is to have a SM + Phoenix implementation that can generate routes and “controller” (state movement?) functions, allowing you to plug custom code at places, all the while keeping all the SM + network delivery mechanisms (again: REST / GraphQL / what-have-you) cruft to a minimum.

The curse of digging a bit deeper into the scientific part is beginning to notice how the world invents and reinvents wheels all the time, and stumbles at the same problems almost every time. So this is just a generic high-level laundry wish-list borne from that feeling. :slight_smile:

yurko

yurko

OK, I understand, though I’d rather implement it myself using low level functionality then have it in Phoenix - it would be way too magick-y otherwise.

There is definitely some truth to that :slight_smile:

dimitarvp

dimitarvp

I sympathize with that point of view. I myself also don’t want the feeling of “things just somehow work” that I got when I was working with Rails. Functional languages’ explicitness is a a huge breath of fresh air for the brain.

Having an optional SM would be the optimal solution – an “advanced” tool for whoever has the experience to use it. However, having a bunch of optional features can only make the framework complex and confusing with time so it’s probably for the best for this to be a community project and not a part of Phoenix…

yurko

yurko

Well, that’s a +1 :slight_smile:

Where Next? Top

Trending in Discussions Top

AstonJ
As the title says, please share what you’ve been up to with Elixir. Whether that’s been learning it, looking into it, making stuff with i...
2977 91898 914
New
AstonJ
The obligatory hello world thread! Who are you and where are you from? :stuck_out_tongue:
4616 55835 594
New
byu
@chrismccord : I just saw the Extract AGENTS.md from Phoenix.new into phx.new generator commit to the phoenix project. My initial shotgu...
New
arcanemachine
I was working on an Ecto migration and I needed a timestamp. So, for the nth time, I looked up the different data types for timestamps, a...
New
alexslade
Fly’s CEO posted this recently - Turn And Face The Strange · The Fly Blog It says that Fly is going all-in on sprites, which is a worry ...
New
Herve37
We’re evaluating API mocking tools for OpenAPI-based projects and would love to hear what other teams are using. We’re particularly inte...
New
matt-savvy
Is there a word for the ~> symbol used in Version strings? Do you also just call it a Squiggle Arrow™ ?!
New

Other Trending Topics Top

JesseHerrick
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
jimsynz
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
mcass19
ExRatatui lets you cook up rich terminal UIs in Elixir, powered by Rust’s ratatui via Rustler NIFs. Build interactive terminal applicatio...
New
Damirados
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve. They are GUI (Emerge) and State management (S...
New
netoum
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
ausimian
Emily is an Elixir library that runs Nx computations on Apple’s MLX. Install it as the default Nx backend and Nx, defn, Axon, Nx.Serving,...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews