I absolutely love Dart and Flutter. Dart is still having growing pains when it comes to back end, but it is insanely performant on native (desktop and mobile) compared to JS frameworks. Dart is very strongly typed like c#.
Agreed, I put Dart up there with the likes of C# and Kotlin in terms of what it is capable of. I just wish people that put so much effort into ecosystems like JS and Java would instead prop up languages like these.
Dart is Google's attempts to do typescript, but instead of a linter it's a whole language (that you can compile to different targets than just browser)
Dart was created to complement (replace) _JavaScript_ initially. They released a Dart-native browser called Dartium. It quickly died out. Then Flow, TypeScript etc. evolved. After a long while Dart was repurposed for Flutter.
Dart has wayyyyy stronger type safety compared to Typescript. It feels more like if a language like C# had a baby with Typescript than Typescript. Also the Flutter ecosystem is kinda big and Dart just released compilation to webassembly so I can see it going places.
You can use flutter not only for mobile applications, but for web and desktop apps as well. It feels weird to hear "you're going to learn a language and then only use it to one thing" .... but at the same time people complain that you can use JS for everything.
The fact that JS can be used for everything isn't the complaint, it's the fact that it's not the best language for all those other use cases. Python would be a more suitable choice, but honestly, I'd rather we ditch interpreted languages altogether; we're at a point where modern compiled languages are just as easy to work with and come with better performance out of the box. Dart, Kotlin, Go, and modern C# are becoming more compelling to work with.
This example also didn’t showcase any of the cool stuff dart has built it. Sound null safety, extensions, streams, isolates, pattern matching. And meta programming is coming which would be like Zig comptime That said you are 100% right it’s deep and it’s not really used outside of flutter so the investment to learn isn’t great if you aren’t bullish on flutter. You can write servers and cli tools but every lang can do that. The biggest advantage it has over TS is its tooling, shit just works and you don’t have the baggage of JS. It’s a pretty cool language but if flutter didn’t exist you wouldn’t even know about it
That summary of dart was pretty painful to listen to. Yes flutter is it's killer app but you can write anything you want in it. It's actually a very nice language with a lot of really nice features and they continue to add to it which is great. With dart 3 they just added pattern matching, and records (tuples). You've got real null safety, a fantastic implementation of async via futures and streams, concurrency and parallelization via isolates, code generation via reflection, etc. It's also got FFIs for c, Java, kotlin, JavaScript, Swift, objective c, etc. It's a really fast language for a GCed language and to be honest I wouldn't be surprised if it becomes more and more popular outside of flutter in the near future. I think of it like a better version of C# with features from languages like kotlin, smalltalk, JavaScript and Erlang. Probably the most painful thing about dart, is that it was a candidate to replace JavaScript and yet the JavaScript community rejected it. We would be so much better off if the dart virtual machine was in every browser instead of these terrible JS engines.
We wrote an app with flutter, and we reused a library we wrote in a dart backend service to also work with google home/alexa. Worked pretty well, but also was low traffic. I think you can natively compile it to a lot of platforms, which is nice.
@@paulerickson5116yeah, I think the original plan was to compile directly to WebAssembly, but it seemed a bit ambitious, so they scratched it for the time being. Hope they revisit it in the future though, could be huge.
Dart is the answer for people like me that don't want to touch to Javascript/Typescript even from far with a stick. And I really appreciate how it's designed (vs. C++, Java, Python).
Believe it or not but Dart had a browser at one point called Dartium, which was a modified Chromium to support Dart natively for, I guess debugging purposes. Their idea was that Dart was going to complement (rather, take over) JavaScript, because it was at one of those times where people were hating on JavaScript before it became cool again-these cycles happens every few years or so. Dart was thrown under the bus for a while until Flutter came along.
final you can’t reassign but is mutable, feels the same as JS const. But const is immutable all the way down. Meaning nothing inside can change also if you are assigning an instance of something it must have a const constructor (like on the enum) This gives some performance wins at runtime for example in flutter it doesn’t have to evaluate the tree past a const widget because it can not change
Think of flutter as having a cross platform UI library which compiles natively to all the 5 platforms built on spirv pipeline and initially based on skia. Its by far the best developer experience I had writing native app and cross compiled UI interfere. There is simply no better alternative for it. Want to modify how your window launches up in linux and windows separately, use the native stack for the platform.
It bugs me that the person doing the implementation didn't opt for the new pattern matching switch expression. Like the impl depends on dart sdk version ^3.0.0. Why?
Dart is cool, but it's missing key features like static metaprogramming. You'll get why this sucks if you code in Dart with Flutter for a while and stuck using code generators (yikes).
I may have just copied the ts code super fast so that I can be first 😀. I now made some changes and used the new pattern matching syntax and removed the shitty ch = \0 constructor thing it was unintended.
Javascript always gets shat on for "immutable" not being immutable in the case of lists and objects, but it's literally the same in every mainstream language.
Dart is very good at backend way better that nodejs, it is a language no some invention of include javascript into some kind of framework shit, you can do API, manipulate OS resources flutter is jut the Front End framework and to be honest I try to go into C# dart and flutter is super fast to build simple apps in no time, I never has to build complicated stuff but for my own tools is really amazing and fast you can create apps and no stupid ones really good front end, and forget writting CSS HTML AND JS just pure DART and you get the job done the widgets in flutter are awesome.
I'm a bit of a noob still but isnt dart usecase having one codebase good ui performance against for example blazor or blazor maui hybrid? One codebase and crossplatoform out of the box is pretty nice and handy for building a quick and dirty app, this seems to make it possible while beeing descently efficient and performing acceptable right?
I firstly found the Dart a pretty weird language :( Then when coding apps in Flutter realised all Dart lang features were suposed to be used inside Flutter letting the development more easy :O
Dart feels a lot like typescript or java to write, except for the formatter. It's so heavily opinionated (so that "all flutter should look the same") that it can make code completely unreadable. I've written some sizable apps with Flutter hand having these huge nested Constructors only indented with 2 spaces makes it incredibly difficult to work with. I was fighting the formatter half the time because there needed to be 2 pixels of offset on some textbox. About the backend comment: I'm pretty sure you could if you wanted to...
Dart is a general-purpose language that has a syntax very similar to Java but better because it has modern features like extension methods and async programming..., and can compile to native assembly applications using the Jit compiler or Aot compiler. javascript or typescript are not much for Dart because they are limited only to the browser.
Alright listen. The front end needs its own damn language. Flutter is indeed the main reason for Dart. Don't use it on the back end. That's dumb. Pair it with your favorite back end language and put together a nice API to connect into all the libraries you need in other languages and let Flutter handle the annoying type systems that you normally have to write yourself in Typescript. All your styles are right there in the widget classes themselves. Yes, I know it's annoying that they call them widgets, but the widget tree is a beautiful construct that makes visual builders like FlutterFlow waaay easier to put together. If you're coding Flutter raw, you're not fully taking advantage of the framework's capabilities.
Hmm… judging by the comments people do really like the language. Personally I’m not sure what Dart brings to the table at this point. It feels like a new language for the sake of a new language.
I mean that's a valid point, I think has to do with the use case it was targeting. Dart has been around for over 10 years, it just failed to replace JS, so it was repurposed for working on mobile and desktop apps because of these traits: great DX, OOP principles (which many JS devs hate for no reason, and it's the best way to represent UIs), productivity and readability, and high performance with JIT (for hot reload) and AOT (for production) compilation. Sure, these traits can be found in other languages, but I think in some aspects, Dart scores better than most languages, specifically DX and productivity.
Rust is also a language for doing very specific things so I'm not sure what you're talking about. Mobile development got 10x easier thanks to dart. React Native is laughably bad on mobile, Native is unnecessary hard. On ios because apple doesn't care about developer experience, on Android because it's based on Java. Additionaly there is server pod which is the only solution for realtime apps. Even firebase doesn't provide such features. Lang is solid and boring, but has nice packages by community that makes it really better than other lang. Freezed, riverpod, dartz etc. The main selling point is hot reload. Just save any file and UI just refreshes. No other technology has that. Really not much to complain
I absolutely love Dart and Flutter. Dart is still having growing pains when it comes to back end, but it is insanely performant on native (desktop and mobile) compared to JS frameworks. Dart is very strongly typed like c#.
Agreed, I put Dart up there with the likes of C# and Kotlin in terms of what it is capable of. I just wish people that put so much effort into ecosystems like JS and Java would instead prop up languages like these.
No no let them thrash it so our salaries remain high lol
Dart is Google's attempts to do typescript, but instead of a linter it's a whole language (that you can compile to different targets than just browser)
Just to point out that it came before typescript. I was surprised it lived this long. 😂
Dart is code once run anywhere so consolidated code to hit 5 platforms
Dart is backend feasible as well
The Dart PR is more complete and pulls in more 3.0 rich
Dart was created to complement (replace) _JavaScript_ initially. They released a Dart-native browser called Dartium. It quickly died out. Then Flow, TypeScript etc. evolved. After a long while Dart was repurposed for Flutter.
It came before Typescript. It was intended as an alternative to Javascript having native browser support as well, didn't turn out that way.
Dart has wayyyyy stronger type safety compared to Typescript. It feels more like if a language like C# had a baby with Typescript than Typescript. Also the Flutter ecosystem is kinda big and Dart just released compilation to webassembly so I can see it going places.
It's great that they fixed it. Dart initially was awful and had no null safety.
How to enable wasm?
You can use flutter not only for mobile applications, but for web and desktop apps as well. It feels weird to hear "you're going to learn a language and then only use it to one thing" .... but at the same time people complain that you can use JS for everything.
The fact that JS can be used for everything isn't the complaint, it's the fact that it's not the best language for all those other use cases. Python would be a more suitable choice, but honestly, I'd rather we ditch interpreted languages altogether; we're at a point where modern compiled languages are just as easy to work with and come with better performance out of the box. Dart, Kotlin, Go, and modern C# are becoming more compelling to work with.
This example also didn’t showcase any of the cool stuff dart has built it. Sound null safety, extensions, streams, isolates, pattern matching. And meta programming is coming which would be like Zig comptime
That said you are 100% right it’s deep and it’s not really used outside of flutter so the investment to learn isn’t great if you aren’t bullish on flutter. You can write servers and cli tools but every lang can do that. The biggest advantage it has over TS is its tooling, shit just works and you don’t have the baggage of JS. It’s a pretty cool language but if flutter didn’t exist you wouldn’t even know about it
Dart debugging and devtools are great. Works really well
That summary of dart was pretty painful to listen to. Yes flutter is it's killer app but you can write anything you want in it. It's actually a very nice language with a lot of really nice features and they continue to add to it which is great. With dart 3 they just added pattern matching, and records (tuples). You've got real null safety, a fantastic implementation of async via futures and streams, concurrency and parallelization via isolates, code generation via reflection, etc. It's also got FFIs for c, Java, kotlin, JavaScript, Swift, objective c, etc. It's a really fast language for a GCed language and to be honest I wouldn't be surprised if it becomes more and more popular outside of flutter in the near future. I think of it like a better version of C# with features from languages like kotlin, smalltalk, JavaScript and Erlang.
Probably the most painful thing about dart, is that it was a candidate to replace JavaScript and yet the JavaScript community rejected it. We would be so much better off if the dart virtual machine was in every browser instead of these terrible JS engines.
We wrote an app with flutter, and we reused a library we wrote in a dart backend service to also work with google home/alexa. Worked pretty well, but also was low traffic. I think you can natively compile it to a lot of platforms, which is nice.
It compiles to machine code everywhere except for web where it’s jvm bytecode
@@paulerickson5116yeah, I think the original plan was to compile directly to WebAssembly, but it seemed a bit ambitious, so they scratched it for the time being.
Hope they revisit it in the future though, could be huge.
Dart is the answer for people like me that don't want to touch to Javascript/Typescript even from far with a stick.
And I really appreciate how it's designed (vs. C++, Java, Python).
Man dart is a language that i love and its sad too see that it only gets used for flutter
Believe it or not but Dart had a browser at one point called Dartium, which was a modified Chromium to support Dart natively for, I guess debugging purposes.
Their idea was that Dart was going to complement (rather, take over) JavaScript, because it was at one of those times where people were hating on JavaScript before it became cool again-these cycles happens every few years or so. Dart was thrown under the bus for a while until Flutter came along.
It was a proof of concept to show you could have the two VMs in the same browser.
Dart linter heavily suggests immutable qualifiers final or const
I've played around with Flutter a little bit and Dart is a neat little language.
final you can’t reassign but is mutable, feels the same as JS const. But const is immutable all the way down. Meaning nothing inside can change also if you are assigning an instance of something it must have a const constructor (like on the enum) This gives some performance wins at runtime for example in flutter it doesn’t have to evaluate the tree past a const widget because it can not change
I love dart, is the exact same syntax of Java but with steroids (null safety, memory safety, type safety, it has a type resolver inside)
I really like dart , my favorite language to date
Think of flutter as having a cross platform UI library which compiles natively to all the 5 platforms built on spirv pipeline and initially based on skia. Its by far the best developer experience I had writing native app and cross compiled UI interfere. There is simply no better alternative for it. Want to modify how your window launches up in linux and windows separately, use the native stack for the platform.
Do Swift next. I think you will like the language, even if it is useless out of Apple environments
You can do - Android, iOS, Windows, Linux, MacOS, Web and also Backend with Dart. Ignorance is bliss.That's how your average JS developers are.
Did he just merge a PR without even looking at the diff. That is mental lol.
There is a better way to do a lot of this now with the latest version of Dart. Want a PR?
Source: was on Dart/Flutter team at Google
It bugs me that the person doing the implementation didn't opt for the new pattern matching switch expression. Like the impl depends on dart sdk version ^3.0.0. Why?
Please make a merge request!
I updated it man sorry
There are many other ways to make this code look better.
@@adriankal like ?
Dart is cool, but it's missing key features like static metaprogramming. You'll get why this sucks if you code in Dart with Flutter for a while and stuck using code generators (yikes).
Feels like java, but that Alphabet will sue you instead of Oracle
two incredibly likable people
What? T.J. seems un-natural.
I may have just copied the ts code super fast so that I can be first 😀. I now made some changes and used the new pattern matching syntax and removed the shitty ch = \0 constructor thing it was unintended.
I'm loving these code reviews. Great little look at different languages. Keep up the great content 👍
Guys, what plugin is used to display nesting hierarchy at the top of the screen?
This series has been so fun!
Dart with pattern matching is great
Nothing like a super sexy pure functional Kotlin Mobile Multiplatform :D
Youre right. It works 🤣
But you still need to code in kotlin for android UI and swift for swiftui where as flutter it's one codebase everywhere
@@hamzakhiar3636 Actually no, i think Compose multiplatform allow you to write UI in Kotlin for Swift too
Javascript always gets shat on for "immutable" not being immutable in the case of lists and objects, but it's literally the same in every mainstream language.
Dart is very good at backend way better that nodejs, it is a language no some invention of include javascript into some kind of framework shit, you can do API, manipulate OS resources flutter is jut the Front End framework and to be honest I try to go into C# dart and flutter is super fast to build simple apps in no time, I never has to build complicated stuff but for my own tools is really amazing and fast you can create apps and no stupid ones really good front end, and forget writting CSS HTML AND JS just pure DART and you get the job done the widgets in flutter are awesome.
I'm a bit of a noob still but isnt dart usecase having one codebase good ui performance against for example blazor or blazor maui hybrid? One codebase and crossplatoform out of the box is pretty nice and handy for building a quick and dirty app, this seems to make it possible while beeing descently efficient and performing acceptable right?
I firstly found the Dart a pretty weird language :( Then when coding apps in Flutter realised all Dart lang features were suposed to be used inside Flutter letting the development more easy :O
Dart feels a lot like typescript or java to write, except for the formatter. It's so heavily opinionated (so that "all flutter should look the same") that it can make code completely unreadable. I've written some sizable apps with Flutter hand having these huge nested Constructors only indented with 2 spaces makes it incredibly difficult to work with. I was fighting the formatter half the time because there needed to be 2 pixels of offset on some textbox.
About the backend comment: I'm pretty sure you could if you wanted to...
Set line length to 1000 and write commas everywhere. Code looks very nice after that.
use the trailing comma lint and enable fix/format on save, makes life much better
Hash code was to uniqify by value
Abstract interface class🤙
Dart is a general-purpose language that has a syntax very similar to Java but better because it has modern features like extension methods and async programming..., and can compile to native assembly applications using the Jit compiler or Aot compiler.
javascript or typescript are not much for Dart because they are limited only to the browser.
Dart actually pretty nice looking language. But I won't gonna learn it anyway)
Alright listen. The front end needs its own damn language. Flutter is indeed the main reason for Dart. Don't use it on the back end. That's dumb. Pair it with your favorite back end language and put together a nice API to connect into all the libraries you need in other languages and let Flutter handle the annoying type systems that you normally have to write yourself in Typescript. All your styles are right there in the widget classes themselves. Yes, I know it's annoying that they call them widgets, but the widget tree is a beautiful construct that makes visual builders like FlutterFlow waaay easier to put together. If you're coding Flutter raw, you're not fully taking advantage of the framework's capabilities.
I can't like the video, it has 420 nice likes
Flutter nothing but Magic
Damn I'm waiting for all
Hmm… judging by the comments people do really like the language. Personally I’m not sure what Dart brings to the table at this point. It feels like a new language for the sake of a new language.
I mean that's a valid point, I think has to do with the use case it was targeting. Dart has been around for over 10 years, it just failed to replace JS, so it was repurposed for working on mobile and desktop apps because of these traits: great DX, OOP principles (which many JS devs hate for no reason, and it's the best way to represent UIs), productivity and readability, and high performance with JIT (for hot reload) and AOT (for production) compilation. Sure, these traits can be found in other languages, but I think in some aspects, Dart scores better than most languages, specifically DX and productivity.
erlang ftw
Rust is also a language for doing very specific things so I'm not sure what you're talking about.
Mobile development got 10x easier thanks to dart.
React Native is laughably bad on mobile, Native is unnecessary hard. On ios because apple doesn't care about developer experience, on Android because it's based on Java.
Additionaly there is server pod which is the only solution for realtime apps. Even firebase doesn't provide such features.
Lang is solid and boring, but has nice packages by community that makes it really better than other lang. Freezed, riverpod, dartz etc.
The main selling point is hot reload. Just save any file and UI just refreshes. No other technology has that.
Really not much to complain
fart/10
Abstract interface class🤙