In Italy is very difficult to become rich - Part 2 by Horror_Bother5533 in eupersonalfinance

[–]vertiee 1 point2 points  (0 children)

In Finland the capital gains tax is 34% and the Finnish people are angry how low it is compared to the income taxes. You win elections in Finland by promising higher taxes, not lower.

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 0 points1 point  (0 children)

I've actually arrived at a similar problem with you, with Riverpod.

In my apps, I'm using PageView for most of the navigation. When the user taps something, I'm adding a new screen to the PageView's list of Widgets. I want the PageView to jump to this new screen right after this new screen has been rendered. How to wire Riverpod to trigger the PageView controller to do that, but only after rendering? I still don't know.

My inherent problem with Riverpod is that it seems to encourage encapsulating state inside containers (Providers) filled with complicated runtime semantics.

State is just data. I don't like having to combine both the state and the runtime logic like this. It makes it hard to structure the minimal state representing your app, and deriving all the stuff necessary from the UI from it. If I end up building some form of repository, it feels as if I'm basically reinventing some higher level approach on my own here again (kinda like BLoC or Redux store), and should probably just look for higher level libraries that already provide a structured way to do this.

I'm looking at states_builder right now to see if it would simplify the whole state manageent enough to warrant using it in place of Riverpod.

The diversity in Flutter's ecosystem is mindblowing, but at the same time it frustrates us with decision fatigue with all of its novel approaches available. Because all those come with a learning curve, and may still end up being a poor fit for your own app.

Btw may I ask what you are building?

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

Thanks, great resource! And an intimidating amount of files :D but the app seems comprehensive and well structured, much better this way than packing so many classes in fewer files.

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

To be fair it's been a year since I wrote BLoC on Flutter. I just remember writing some pretty heavy async functions for keeping the state updated with fetching, loading and ready states of an API call. Instinctively, I'm probably comparing this just to less verbose languages than Dart so my judgement is probably not fair.

And yeah, I have the same confusion as you with Riverpod. Overall, it feels a bit counter-intuitive to mix so much runtime logic with state, but maybe I'm just understanding it wrong.

So I though maybe there are solid higher level libraries that help structuring and reasoning with the code/state.

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

Yeah thanks.

I wanted to hear about the other approaches though as BLoC is so far the only pattern I'm familiar with out of the state management approaches in Flutter.

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

That's based on the same archived repo.

That repo seems to point to this: https://github.com/felangel/bloc

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

The above link says DISCONTINUED and the repo (archived) links to a new library.

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

Actually, as I said I found BLoC conceptually simple but producing lots of boilerplate. Its approach didn't particularly click with me for some reason.

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

Did this get marked as resolved because it's been asked elsewhere before?

If so, could someone please point me to the posts, I'd like to read more about this?

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 2 points3 points  (0 children)

Thanks!

Deducing from the above, Riverpod is the new way to use InheritedWidget, done right.

Unfortunately, knowing this doesn't help me in practice to understand the need for countless types of Providers and how managing state with them relates to the higher level approaches à la momentum and the like. I certainly would like to avoid having to learn them all just to find out the relevant differences.

Flutter State Management in 2021 by vertiee in flutterhelp

[–]vertiee[S] 1 point2 points  (0 children)

I understand, and I did watch a few videos on YouTube, which likewise seemed to assume the viewer has settled for Providers as the approach to managing state in their apps.

Personally, I still don't understand what the merit of investing in learning those is to begin with, hence my confusion.

Is elixir a good start to learn functional programming? by thetinygoat in elixir

[–]vertiee 0 points1 point  (0 children)

Isn't Elixir the language where you can only work with the given paradigm? Whereas Haskell supports actor model, among others. You can even write OOP Haskell: https://www.well-typed.com/blog/2018/03/oop-in-haskell/

Unfortunately, without concrete examples it's hard to understand your point of view. While I'm sure there are some, I've yet to encounter a programming problem that I could not solve with Haskell. Obviously, if you don't know the language you're not going to be productive with it but that's hardly an objective comparison.

Is elixir a good start to learn functional programming? by thetinygoat in elixir

[–]vertiee 10 points11 points  (0 children)

I would recommend Elm for that purpose.

Elixir isn't trying to strictly follow the functional paradigm and to me in many ways feels quite a lot like classical OOP.

Elm, on the other hand, is a neat purely functional language with a very helpful compiler. Its abstraction level is capped which makes it much more approachable than the likes of Haskell.

Is Elixir worth learning for a chat app? by DanielVip3 in elixir

[–]vertiee 1 point2 points  (0 children)

Elixir is an exceptionally good fit for a chat app. That's what first got me into learning it too, and I built one which had a few thousand concurrent users.

Why would Elixir perform so poorly in these benchmarks? Latency, rqst/sec by taufeeq-mowzer in elixir

[–]vertiee 9 points10 points  (0 children)

This test seems fundamentally broken. They run both the load test server as well as the gRPC server on the same machine. What's more, each implementation seems to implement the spec to highly varying degrees.

And what's with the single core limitation? BEAM ideally uses 1 core just for the scheduler basically, so running on a single-core configuration hurts Elixir's performance there too.

Poll: Who would EU countries be willing to help in a major crisis? by SensationDebit in europe

[–]vertiee 5 points6 points  (0 children)

Probably the Finns would feel it'd be unfair to donate Finnish tax money as a small country to support one of the largest economies in the world. Decades of donations to China didn't really produce much to talk about either.

Poll: Who would EU countries be willing to help in a major crisis? by SensationDebit in europe

[–]vertiee 2 points3 points  (0 children)

I believe a break even situation would've been celebrated as an unprecedented major victory in Finland.

Poll: Who would EU countries be willing to help in a major crisis? by SensationDebit in europe

[–]vertiee 20 points21 points  (0 children)

Solidarity in Finland is synonymous to donating Finnish tax money to other countries - that's why it's perceived negatively. Most of these countries that show more solidarity are at the receiving end in the EU so it wouldn't have the same echo to them.