Angus - How To Code It

78 posts

Angus - How To Code It banner
Angus - How To Code It

Angus - How To Code It

@how_to_code_it

Founder, How To Code It | Rust expert | Sharing practical guides to help you write the best Rust of your career

United Kingdom Inscrit le Ekim 2023
66 Abonnements262 Abonnés
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
Part 4 of my deep dive into hexagonal architecture in Rust is live! 🦀 Covering: 🤔 Trade-offs of hexagonal architecture ⛔️ Common pitfalls to avoid 📈 Adopting hexagonal architecture at every growth stage Read & subscribe for updates: howtocodeit.com/articles/maste… #Rust #RustLang
English
7
5
46
1.4K
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@nnrm_04 I know, I know! It’s been crazy over here with RustConf, etc. I’m planning to blast out a site upgrade this weekend to better handle rich, multi-part articles like Hex Arch has turned into, then I can write freely. Thanks for bearing with me!
English
0
0
1
19
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@SebasDev1 @alicelovescode It’s in the works! Between RustConf, a new job and some much-needed CMS upgrades, I’ve been strapped for time. My RustConf talk will probably be the next thing to be published, along with the final parts of the hexagonal and error handling articles.
English
0
0
3
31
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@tomjohnson3 Hey Thomas! I think you’ll find part 4 (out next week) really helpful. It’ll address the relationship between hex arch and microservices in some detail - there’s a lot of overlap and transferrable technique. Thrilled to hear you’re finding the guides useful!
English
0
0
1
19
Thomas Johnson
Thomas Johnson@tomjohnson3·
@how_to_code_it ...perhaps there's something from hexagonal architectures that we could get inspiration from as we design this feature? [3/3]
English
1
0
0
39
Thomas Johnson
Thomas Johnson@tomjohnson3·
Launching an MVP with “whatever architecture works, we'll refactor later” always ends with “we have an early-stage product that's already legacy”.
English
2
0
2
72
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@alexelcu Is this equivalent to saying "don't ruin your presentation with fonts that aren't Times New Roman"? If you don't have an eye for design your presentation will look bad wherever you source your images.
English
0
0
1
33
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@hexwanderer I'm struggling to think of any use case for this? If you could declare `let x: impl SomeTrait`, this would get compiled to `let x: YourImplementation`, so you might as well just write `let x: YourImplementation`.
English
0
0
0
89
Winston
Winston@hexwanderer·
@how_to_code_it Thanks for your reply! Sometimes I want to just do it at the top level, there isn’t an easier way to do it without declaring a function?
English
1
0
0
21
Winston
Winston@hexwanderer·
@how_to_code_it hi angus! i have been trying to follow your guide on hexagonal arch, but i frequently run into situations where I want to declare some variable as an impl of a trait, but am repeatedly told that the trait is not object safe. Only way to solve is to pass into fn?
English
1
0
0
33
Gaurav Kumar
Gaurav Kumar@cereal_learner·
@how_to_code_it Sir, can you kindly take my 🫡 your blog posts on hexagonal architecture are mind-blowing. What I really appreciate is it's not just words-wisdom but code-wisdom. Please keep them coming :-)
English
1
0
1
22
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@k_pendergrast What other construction do you think would achieve the same tone? 🤔 The intended reading is clear, even if we do have to say a few Hail Marys afterwards.
English
0
0
1
18
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@hexwanderer If you call `fn f(x: impl SomeTrait)` with `StructThatImplsSomeTrait`, it’s compiled to `fn f(x: StructThatImplsSomeTrait)`. This happens for every distinct type that impls `SomeTrait` – multiple copies of the function are compiled (the technical term is monomorphization). [5/5]
English
1
0
0
80
Angus - How To Code It
Angus - How To Code It@how_to_code_it·
@hexwanderer To do it generically instead, assign a variable of the concrete type that implements `SomeTrait`, and pass it to functions or structs bounded by `impl SomeTrait`. Be aware: `impl` doesn’t indicate any dynamic dispatch...[4/5]
English
1
0
0
37