AstonJ

AstonJ

I’ve not had a chance to read this myself yet (on mobile) but noticed he’s just released this.

Some older discussions on the topic can be found via the elixir-for-programmers-course tag :smile:

For a while now I’ve been doing my Cassandra impersonation, telling everyone who’ll listen (and quite a few folks who won’t) that we need to be writing code in smaller chunks. I know what happens when we don’t, as I was the author of one of the largest early Rails applications (65kloc), and it became a nightmare to work with.

I don’t want the same thing to happen in the Elixir world. But if I’ve learned one thing, it’s that you can’t tell people that something is a good idea and expect them to do it.

No, you have to make it easier to do things the right way.

So, I’m releasing a first version of my Elixir Component library.

Anyway, the philosophy of all this is not to save on typing. Instead the intent is to nudge people into writing their programs using lots of small, independent components, linked via dependencies. That’s how I’ve been coding for the last year or so, and so far I’m really, really liking it.

Tutorial/guide: component/README.md at main · pragdave/component · GitHub

Blog post: Small is Beautiful—The Component Library

GitHub: GitHub - pragdave/component: Experiment in moving towards higher-level Elixir components · GitHub

Tweet: Dave Thomas on X: "I've finally had the courage to release my Elixir "Component" library, designed to encourage the building of deliverables using decoupled, coherent, components. • https://t.co/BeitIi7DyY • https://t.co/9Qhn1aiS8g @elixirlang #myelixirstatus" / X

Showing Posts 1 to 10

kblake

kblake

I’d recommend reading the README over the blog post as it has more thorough examples. I’m curious to hear what others think!

AstonJ

AstonJ OP

Yeah I agree, I labelled it as a tutorial in the post above as it seems quite in-depth :smiley:

Unfortunately I haven’t got time to go through it right now though, so looking forward to hearing what everyone else thinks as well :003:

otuv

otuv

Reading the README it seems about right. I have had similar thoughts for quite a while but I have yet always failed at the implementation. My hopes is that this, or resulting best practices and examples could help me get of the ground.

AstonJ

AstonJ OP

Have you (or anyone else) seen his Elixir for Programmers (PragDave) course… does it differ much to that?

otuv

otuv

Unfortunately not. But reading the reviews it sure looks like something I should have been looking for!

axelson

axelson

Scenic Core Team

Yeah it different substantially since this is a library that implements the GenServer structure that he advocates for in the course and a little more.

sfairchild

sfairchild

I went through the course about 2 months ago. It was great and he is really a great teacher.

I haven’t had the time to read the full article or README yet, hopefully tonight I can sit down and review it. But from the little snippet I did read it was very similar to the approach he taught.

jeremyjh

jeremyjh

I’m a little bit concerned that this (blog post at least) encourages people to use servers where only modules are needed. In web applications for example, putting your application logic in a GenServer is an anti-pattern as it will lead to single-threading your requests, not to mention all the copy operations. I can’t argue that raw GenServer requires a lot of boilerplate but ex_actor has been cutting down the boilerplate for 5+ years. Is there more to it?

11
Post #8
axelson

axelson

Scenic Core Team

@jeremyjh that sounds like a good point to bring up on the issues list :slight_smile:

AstonJ

AstonJ OP

New video:

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