Comments by "Ozzy Perez" (@OzzyTheGiant) on "ThePrimeTime"
channel.
-
You and me both! The only way I can win the battles is by forcing Class components where possible, using a sensible state management system (no Contexts, I don't want giant component trees looking like bird wings), separating concerns as much as possible, keeping components small, and organizing code in functional components so that variables are the top, followed by closure functions (functions that don't need the outer scope get tossed out of the component or in another file), then effects, then any logic for data transformation, and finally the render. People need to learn standards, for god's sakes!
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
2
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
JS Kiddies, buckle up, I'm gonna tell you my honest opinion about PHP and why I like it:
- PHP > Python and JS: Its syntax is just easier to read. Yes people hate the $ but honestly it points out variables more quickly
- PHP is arguably the fastest of all the interpreted languages. According to TechEmpower benchmarks, raw PHP is almost as fast as C++
- I like that PHP is multiparadigm but it leans in favor of OOP, especially from 7.4 onwards. You can pass around functions (defined as Closures) and you can pass in higher scoped variables into said Closures, but the syntax is not as convenient as JS, which is fine because it's a lot easier to define static functions for a class and pass those around or call them instead; I think this leads to cleaner, more readable, organized code. Namespacing is a big thing part of that.
- PHP now has Fibers, the equivalent of Python threads and JS workers, so I don't see any reason these two have any advantage over PHP here.
- There is no reason to use the templating syntax that PHP comes with out of the box. You can just use Twig, which is a common template language in other ecosystems.
1
-
1
-
1
-
1
-
1
-
1
-
15:57 - Absolute trash, soy, L take
On another note, I'm really glad we are talking about this, just based on the content and the Twitch comments I saw. I feel like this is something that all of us as developers need to balance out well, the choice of what language to use based on what we like vs what gets the job done.
For example, I don't like using Java. I don't hate Java itself (it's really come a long way and paired with Kotlin it's nice), but I just don't like the ecosystem around it (using XML for configs, hard to read docs for so many things, Spring/Hibernate is a nightmare). That said, the devs that have been in that side of the web dev field don't care about your petty feelings and they will continue to use Java because it's efficient for them and it works well for their use cases. I still won't use Java but if that ever has to be a project requirement, if I have leverage, I could at least advocate for a stack that works well for what I want, like: JOOQ query builder, Koin dependency injection, Javalin framework, and use Kotlin where I can.
Rather than choosing stacks because we like them or because they're popular, we should be choosing stacks that make us feel productive. Go is such a language for that. That's why my default stack now is Go (back end), TS/Svelte (front end), and Dart/Flutter (mobile, desktop, cross-platform), maybe Python if machine learning is involved.
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1
-
1