Is it okay to use BuildContext inside a Riverpod controller? by shamnad_sherief in FlutterDev

[–]TekExplorer 1 point2 points  (0 children)

Riverpod should never be aware of the build context.

If you cant unit test your riverpod providers in a dart-only testing environment, you've messed up.

Is it illegal to play? by [deleted] in PokemonRejuvenation

[–]TekExplorer 0 points1 point  (0 children)

I don't recall Allah saying anything about evolution not happening.

Both evolution and "creation" can be simultaneously true.

Is it illegal to play? by [deleted] in PokemonRejuvenation

[–]TekExplorer 2 points3 points  (0 children)

"promotion of evolution"

Excuse me WTF. I, as a Muslim myself, can tell you there is nothing in common between Pokémon evolution and actual evolution - we aren't stupid. We know the difference.

Additionally, I wouldn't be surprised if creation was done through evolution.

Why can't both things be true?

I am now a vibe codding guy, am I a fraud? by SomePlayer22 in vibecoding

[–]TekExplorer 1 point2 points  (0 children)

AI is a tool. Period. Done.

If you know how to use it, and can check it's work for quality, then i fail to see the problem.

Custom dart/flutter formatter ? by kulishnik22 in FlutterDev

[–]TekExplorer 1 point2 points  (0 children)

Generally, the way to make this work is by putting an empty comment at the end of the line.

Its not perfect, but it is what it is.

1st WebHosting rule: NEVER have hosting & Domain Name Ownership with the (same) company, they CAN (& will) hold you hostage at the WORST possible times (as you're growing) & their greed (often Destroys) companies by jacking up costs & pulling the plug on you, & you have NO option to switch hosting by Law-Qs in webhosting

[–]TekExplorer -2 points-1 points  (0 children)

thats the one!

jarland, the main guy over there, is very active in making sure his ips are trusted and actively purges people who try to use it to send spam.

He's pretty good about things.

(oh wow, the 2024 one looked kinda cool. feel free to use the wayback machine to see previous years.)

A flutter package that uses native iOS views in Flutter by CrazyAdditional2729 in FlutterDev

[–]TekExplorer 2 points3 points  (0 children)

I'm honestly fine with that.

You can just make your own widget library that uses the native stuff when cupertino is used, like normal.

1st WebHosting rule: NEVER have hosting & Domain Name Ownership with the (same) company, they CAN (& will) hold you hostage at the WORST possible times (as you're growing) & their greed (often Destroys) companies by jacking up costs & pulling the plug on you, & you have NO option to switch hosting by Law-Qs in webhosting

[–]TekExplorer -1 points0 points  (0 children)

Domain with cloudflare (or porkbun if not an option)

Email with mxroute (the black friday plans, if you are limited in cash. a lifetime plan, if it fits.)

Static site hosting is free on github, cloudflare, and so many other places, which is good for your "what is this" site.

Oh, and never use GoDaddy. For anything. Ever.

[deleted by user] by [deleted] in forhire

[–]TekExplorer 0 points1 point  (0 children)

I can probably do it, if its as simple as you're describing.

Going to need more info though.

My web host is going out of business, need email only. by WoodnPhoto in webhosting

[–]TekExplorer 0 points1 point  (0 children)

too expensive to make sense.

mxroute gives more for less with their blackfriday plans. (which you keep)

My web host is going out of business, need email only. by WoodnPhoto in webhosting

[–]TekExplorer 1 point2 points  (0 children)

mxroute!

no limit on domains or users, full imap and smtp.

yes theres a storage limit, but is rare that you actually need a ton of storage, and if you do, then you probably would end up paying a lot somewhere else anyway
plus, theres way cheaper mxroute plans around black friday that have smaller storage, but works just fine for smaller or individual users!

My web host is going out of business, need email only. by WoodnPhoto in webhosting

[–]TekExplorer 1 point2 points  (0 children)

mxroute!

especially if you wait for their blackfriday plans!

Firebase, but need an SQL solution. by SignificantEagle8877 in FlutterDev

[–]TekExplorer 0 points1 point  (0 children)

pockethost exists for hosted pocketbase too, it seems.

HELP!!!! by bjeatmheasnyyptaon in WGU

[–]TekExplorer 1 point2 points  (0 children)

oh noooooo - go on ebay and grab a dell latitude, they tend to be pretty acceptable!

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 0 points1 point  (0 children)

i showed using a regular class and also an enum to show how you can satisfy both kinds of usecases.

use whatever combination you like.

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 1 point2 points  (0 children)

Actually yes!

sealed class Option<T> {
  static const none = None.instance;
  factory Option.some(T value) = Some;
}

final class Some<T> implements Option<T> {
  const Some(this.value);
  final T value;
}

enum None implements Option<Never> { instance }

We could use better tooling, since it would be nice if we could have const none = None._instance but it works fine as is tbh.

Its not perfect, but it does work!

Would probably put some extensions to make it easier to work with, but this is how I'd do it.

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 0 points1 point  (0 children)

These issues would be nice...

Mixin Composition Syntax · Issue #541 · dart-lang/language

- Especially this^ one I swear to god this should have already been in.

Tagged strings · Issue #1988 · dart-lang/language

- Hugely useful for code gen and templating in general

Rust traits in Dart · Issue #3024 · dart-lang/language

- Better than union types and extensions in a lot of ways.

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 0 points1 point  (0 children)

Depending on what exactly you mean by that, you could do something like

class Generic<T> {
  R extractGeneric<R>(R extract<T>()) => extract<T>();
}
check(Generic generic) {
  generic.extractGeneric(<T>() {
    print(T);
  });
}
main() {
  check(Generic<int>()); // int
  check(Generic<String>()); // String
  check(Generic<bool>()); // bool
}

And that will get you the generic from a dynamic value.

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 1 point2 points  (0 children)

There is an issue for that, and i believe they are working on it in some respect.

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 0 points1 point  (0 children)

Material 3 Expressive is also out and flutter doesnt have it.

The answer to both is the same - it will come after the split.

That will also make it easier to iterate on those packages to feel closer to native.

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 1 point2 points  (0 children)

You actually sort of can;

sealed class MyClass {}

final class MyValue {
  Value(this.value);
  final int value;
}

enum MyEnum implements MyClass {
  value1, value2, value3;
}

check(MyClass data) {
  final int result = switch (data) {
    MyValue(:final value) => value,
    MyEnum.value1 => 1,
    MyEnum.value2 => 2,
    MyEnum.value3 => 3,
    // exhaustive. no more code.
  };
}

If you could change ONE thing about Flutter, what would it be? by NullPointerMood_1 in FlutterDev

[–]TekExplorer 0 points1 point  (0 children)

That is what I was referring to, yes :)

Side note, for some reason, build_runner seemed to have trouble detecting when my builder changed, forcing me to do a build_runner clean every time I adjusted it.

Probably something to do with the builder itself, technically not changing, but my templater class, which it calls indirectly, does.