Live data from Hacker News

Announcing Dart 2 Stable and the Dart Web Platform

medium.com

161–170 of 259 posts

Re: Announcing Dart 2 Stable and the Dart Web Platform

#161

I mostly spend my days writing Go (previously Python) and when I tried Dart I really liked it. Could basically start coding and be productive without even looking at language documentation (VSCode has a nice Dart plugin which tells you what to do and what not to do). In my case, I was trying out Dart because of a Flutter (probably majority of people are now looking at Dart because of Flutter) and I found it really fa…

> If you want to try building a mobile app then definitely go for Flutter+Dart, even if you don't need to support both Android and iOS I think it's just much more easy to start with than alternatives (RN/Swift/Android Java). How is it easier? You can literally start your React Native development by opening up https://expo.io and scan a QR on your phone.

I prefer something that you can build yourself so expo wasn't an option for me. Plus, I think most of the platforms one day (might be soon) will ban these services as they can deliver code to the app after it has been approved.

With Flutter it's super easy, they have a CLI that creates an initial boilerplate for your code that you can compile and deploy to your phone in just a single command with hot reload enabled. I guess it makes it easier even than expo as you don't have to scan anything on your phone :)

Re: Announcing Dart 2 Stable and the Dart Web Platform

#163
post #38

I mostly spend my days writing Go (previously Python) and when I tried Dart I really liked it. Could basically start coding and be productive without even looking at language documentation (VSCode has a nice Dart plugin which tells you what to do and what not to do). In my case, I was trying out Dart because of a Flutter (probably majority of people are now looking at Dart because of Flutter) and I found it really fa…

How does your experience with Dart compare to TypeScript in VS Code? I haven’t tried Dart yet but my TS experience sounds similar to what you described.

I tried to like TypeScript a bit more than a year ago but couldn't, maybe I should give it another chance. I mostly do my frontend development in Vue.js so even though it supports TypeScript, I never found any need for it (I use typed Props to pass data between the components) as I try to make my UI as thin as possible, just fetching some data from the backend and displaying it. You can have a look at my project- https://webhookrelay.com (management UI is under my.webhookrelay.com), so far made it quite simple, material UI and only a little bit of JS.

Obviously coming from Go to frontend I think I would benefit a lot from TypeScript.. Maybe one day :)

Re: Announcing Dart 2 Stable and the Dart Web Platform

#164
post #102

Flutter seems like the killer app that could revive Dart. In comparison: Javascript For mobile with React: no AOT compile. Relies on loading the entire JS VM which adds startup time and can require bundling a large library on Android. Cannot easily author customized components that render at native speeds. C# For mobile with Xamarin: No hot reload. Dart having its origin as a JS interpreted language had the foundatio…

Depending on how far you want to stretch it Kotlin is cross-platform-ish.

You can write Kotlin that compiles to both JVM and JS, and KotlinNative claims to be able to then also compile that to native.

It's hard to do, and there's a major lack of abstractions even within the standard library, but technically possible. I could easily see a future where your business logic is portable kotlin and then you have platform-specific UI layers.

Re: Announcing Dart 2 Stable and the Dart Web Platform

#165

Earlier quoted context omitted.

> A language by itself is almost never useful, every language needs a killer app, I don't understand why this myth is still around. C++ never had a killer app to start its momentum. Neither did Javascript. Nor Java really (or maybe applets, back in the days?). Languages can succeed on technical merits alone if they come out at the right time and fix real problems that programmers experience on current mainstream lang…

Golang and Rust also didn't have any killer app.

Rust definitely has Firefox

Re: Announcing Dart 2 Stable and the Dart Web Platform

#166
post #124

Earlier quoted context omitted.

I think a lot of what people found off-putting about Dart is that Google already recently came out with a new language that has become very successful. Announcing another one, which at first glance looks like yet another curly brace language not that far from Java, was a step too far for people to be interested. Nowadays, the only thing driving Dart seems to be Flutter, which again is head-scratching. Like, "Flutter…

I could be wrong, but I don't believe the existence of Go was much of a problem. Go and Dart are very different languages aimed for very different use cases. If anything, I think Go helped us because we could point to it as a successful language that Google hasn't cancelled. > not that far from Java This is something that hurt us, I think. You can write Dart code that looks a lot like Java, and many of our early publ…

The thing is, this is almost identical to well written JavaScript. In fact you could do almost all of this in JS even before ES5. So the non-Java-like features you're using here were already present, which again suggests that Dart isn't really getting past the "Good Enough" problem.

It's also something you could do in Java, with the exception of having to wrap main with the obligatory EntryPoint class.

I think this just goes to show that good code can be written in almost any language (except Perl of course) because writing good code almost always just means writing obvious code, which necessitates avoiding cleverness and obscure features (literally all of Scala), twisting control flow (I'm looking at you State monads and call/cc), or adding too many indirections due to limitations of the language (Java).

Re: Announcing Dart 2 Stable and the Dart Web Platform

#168
post #155

Earlier quoted context omitted.

I could be wrong, but I don't believe the existence of Go was much of a problem. Go and Dart are very different languages aimed for very different use cases. If anything, I think Go helped us because we could point to it as a successful language that Google hasn't cancelled. > not that far from Java This is something that hurt us, I think. You can write Dart code that looks a lot like Java, and many of our early publ…

I removed everything that seems redundant. Less syntax means less to break, and less for new programmers (who are 10x the volume of existing programmers) to learn: import 'package:hauberk/src/engine.dart' import 'package:hauberk/src/content.dart' content = createContent() save = content.createHero("blah") while (true) watch = Stopwatch() watch.start() # Generate a dungeon at each level. count = 0 for (i = 1; i = -1)…

[deleted]

Re: Announcing Dart 2 Stable and the Dart Web Platform

#169
post #137

Earlier quoted context omitted.

These days it's mostly about apps, because apps are the main thing that facilitate the transfer of $$$. In the 80s and 90s, enterprises were full of $$$ and needed fast and safe languages for writing all their software. C++ came out to solve this need, and Java came out saying it could do it better. Today enterprises are moving many of their internal tools to the web. Enterprises don't need apps per se, but they do n…

> In the 80s and 90s, enterprises were full of $$$ More than today?

I haven't had my caffeine yet today cut me some slack :)

Re: Announcing Dart 2 Stable and the Dart Web Platform

#170
i would have totally jumped on the flutter bandwagon except i feel flutter missed a huge opportunity by not supporting web as a target. microsoft's react-native-xp seems like the right direction. i'd love to hae a combination of dart's sound typesystem + react-native-xp's api.
Post reply on HN