Quick tip: How to make HTTP requests (Dart)

Jermaine Oppong on August 02, 2018

It's quite common to build web applications that pull in data from other web applications, initiated by logic that performs HTTP calls to third par... [Read Full]
markdown guide

Thanks for this. Followed!
Which IDE do you use?

I'm having trouble getting your HttpRequest.getString to work on an actual web app... works fine on DartPad, but not in an IDE. I use WebStorm (seems to be most popular / supported.)
I've gotten basic apps working with both webstorm templates 'bare bones web app' & 'console application'. But following similar steps, pasting your code, running, returns empty browser tabs. and no console printout. (What makes it 'just work' in a DartPad?)

Many thanks for any insight... I'm a Swift dev, an Xcode guy, and brand-new to web development:)


Hey @teknohipy , I use Visual Studio Code with this extension. Also, I've launched a new blog at creativebracket.com. Do check it out for more tutorials :)


Thanks man, i'll try it out. Will check out your blog too.

IDE choices aside though... what else is needed to build your code into an actual working program?

(like i asked "What makes it 'just work' in a DartPad?")

It seems, "DartPad" just gives console printouts, for those who don't have an IDE... but, unless your code actually runs in an IDE, producing output (ie console printouts) can you really call it a working program!

what else is needed to build your code into an actual working program?

The webdev tool by the Dart team handles serving and bundling web-based projects. It works out-the-box with the project structure below:


It would be a good idea to look at stagehand by the Dart team. It generates the scaffolding for a project including the necessary packages. I've got some video tutorials on my YouTube channel going through this.

code of conduct - report abuse