Note We have this thing at Google called "learning on the loo". Posts put up in bathrooms all over the company. Seriously. Anyway, I got one published on September 23, 2024. Greta Googler has been trying to find a resolution on a design decision for weeks. Tessa Techlead doesn't understand the importance of the change and isn’t giving actionable feedback. Otto Othertimezone only replies to the…
Hey folks! It’s high time I modernize this blog. Almost 8 years ago, I moved this blog to Firebase Hosting using a Jekyll static pipeline. Today, I took the ultimate leap: I migrated the entire blog to Dart and Jaspr! Here is the complete migration commit: c79f474367 . 🛠️ The New Shiny Tech Stack By moving away from Ruby and Jekyll, I’ve unified the blog entirely under the Dart ecosystem. Here…
Hey, folks! Almost 3 years ago, I blogged about moving my blog from Blogger to GitHub . It's high time I moved back to Google, right? Here's the commit that updated my config. The only other wiring was setting the FIREBASE_TOKEN in Travic-CI to the value returned by running firebase login:ci . That's about it. "push to deploy" still works like a champ. The turn-around is super fast. Oh, and it's…
tl;dr: Define personal, project-specific shell commands as a git alias. It's nice. I moved to Jekyll for my blog in July. To run the blog on my dev machine I need to run > bundle exec jekyll serve --baseurl '' Not too crazy, but it's a pain to remember every time I want to run the dev server. I could put a helper script in the root of the directory for my personal blog, but that's not an option…
There's a lot of JavaScript libraries. It'd be nice if you could use them seamlessly from Dart, while maintaining Dart's developer-friendly ergonomics. At the Dart Summit in April, Dan and I talked about our plans for the future of JavaScript interop: the hashtag-able #byojsl – Bring Your Own JavaScript Library . With the latest preview release of Dart 1.13 – 1.13.0-dev.7 , you can now play with…
As I posted and tweeted about yesterday, I wanted to see if anyone had experience going from Blogger to Jekyll on GitHub . No one chimed in, so I dove it. I need to do some work on theming, but things seem great so far. Finally blogging in Markdown. So nice. If you want to take a look at my (evolving) configuration, the source is here .
tl;dr If you're using unittest , make sure you have an upper-bound on the package version in your pubspec.yaml . The new (unit)test package is almost ready and it's awesome. The 0.12.0 release will be the migration point from unittest to test . Folks who use unittest will be able to upgrade to 0.12.0 and will get an exported version of test. You'll notice some breaking changes and a lot of…
A while ago, I wrote about using Travis to add continuous integration to your Dart projects. I've started adding a new trick to tool/travis.sh : format verification. I add a script to my tool directory: #!/bin/sh dart_files=$(git ls-tree --name-only --full-tree -r HEAD | grep '.dart$') [ -z "$dart_files" ] && exit 0 unformatted=$(dartfmt -n $dart_files) [ -z "$unformatted" ] && exit 0 # Some files…
You might have heard that Angular is going to be using TypeScript . This has lead to questions about the relationship between Angular and Dart. Let me see if I can help. First, Angular 1. Angular 1 JS is crazy popular. Mountains of folks use it. It’s awesome. Angular 1 Dart was a hand-rolled port of Angular 1 JS. It tried to follow the JS flavor of the framework, while being a true Dart framework.…
Test your package stable and dev If you’re using Travis CI , it’s as easy as adding a dart: entry to your .travis.yml file. You can specify dev , stable or both to make sure your code works great on current and future build of the Dart SDK. language: dart dart: - dev - stable See the dartdoc project for an example. Here’s a build report for dartdoc on Travis CI. Getting code coverage with…
A month ago I asked a question on my blog about a piece of Dart code. For the below class, what are at least two things wrong with the implementation of operator == . class Foo { int _a ; int _b ; int get a => _a ; int get b => _b ; ... bool operator ==( Foo other ) { return other . _a == this . _a && other . _b == this . _b ; } } A number of guesses were posted to the G+ discussion . Context:…
The Dart Editor ships with a Minesweeper-inspired game – Pop, Pop, Win! – that I originally hacked together in late 2012. About a month ago, I made an open request for a Dart community member to port the Pop, Pop, Win! demo to StageXL – a powerful and flexible 2D graphics library for Dart written by Bernhard Pichler . Alex Gann stepped up and delivered. Once Dart v1.4 is released, you'll be able…
Update 1: I was delighted, but not totally surprised that someone else thought this was a good idea – 2 months ago. Patrice Chalin wrote up the proposal on his blog in February and filed a feature request . I've closed my request as a duplicate of his. Disclaimer: This is not in anyway official. It's an idea. If you're excited about it, great. Please star the associated issue . I'm trying to judge…
Specifically with operator == . class Foo { int _a; int _b; int get a => _a; int get b => _b; ... bool operator ==(Foo other) { return other._a == this._a && other._b == this._b; } } Any guesses?
tl;dr: Want an interesting Dart project? Port Pop, Pop, Win! to StageXL . If you do a good job, you're code will get into the Dart SDK. When I wrote Pop, Pop, Win! I hacked together an HTML Canvas graphics library into bot_web . The library – bot_retained – did everything I needed, but I really haven't done much with it in over a year. In the mean time, StageXL has been going nuts. It supports…
For historical reasons, the Dart project uses Subversion for source control. There are a few folks who would like to use Git for the project, including me, but it's not the top of our priority list. You can get some of the benefits of Git by looking at or even cloning our GitHub mirror . One of my favorite uses: tracking changes to an individual package. Steps 1 - Navigate to a package of…
tl;dr Update: this guidance is specific Dart packages . I'll write about Dart apps soon. Read about the Pub Versioning Philosophy . If your package uses new features in the SDK or packages, make sure you set an inclusive minimum version constraint – >= X.Y.Z – to avoid breaking folks who have not yet upgraded. Set exclusive maximum version constraints – <X.Y.Z – to make sure major releases of the…
9:15am 7 Feb, 2014 These changes have not been released to the pub site yet. tl;dr If you're testing code using Future, Stream, or anything async, you'll notice a lot fewer crashes and a lot more helpful stack traces. If you're subclassing Configuration , keep reading. If you're using APIs on TestCase , keep reading. If you're just using test, group, expect, etc. you're likely fine. Update pub…
Follow the instructions here: http://docs.docker.io/en/master/installation/google/ Assuming the last instruction works: sudo docker run busybox echo 'docker on GCE \o/' Run this: sudo docker run sethladd/docker-dart dart --version You should see something like: Pulling repository sethladd/docker-dart 3df1fbb95c1f: Download complete 8dbd9e392a96: Download complete 5581b213d8ed: Download complete…
I have much less to say than the last two times I posted about changing jobs. After 5 years freelancing, I'm going (back) corporate. After running around the Southern US and South America, my wife and I are ready to settle back in Seattle. After coding in C#, XAML, Ruby, and Javascript, I've finally found a development platform that I'm totally in love with: Dart . I want to make it better full…
If you do any open source development on Mac, you're probably using Homebrew . (If you haven't heard of Homebrew, read up here .) I've created a Homebrew formula that will install the Dart SDK, Dart Editor, and optionally content_shell for headless browser testing. Step 1 : "tap" my Homebrew repository to add the dart-editor formula to your Homebrew installation. ~/> brew tap kevmoo/kevmoo Cloning…
About a year ago I posted on the improving output size of Dart to Javascript (dart2js) compiler. For Pop, Pop, Win! , I was taking the ~441KB output from dart2js, pumping it through the Google Closure Compiler to get a Javascript file around 389K. With gzip over the wire, the download size was 90KB. My words at the time: I certainly don't feel I need to justify the javascript output size for…
You know you can create your own git commands right? Git supports custom aliases . They rock. The hello world examples are just creating shortcuts for existing commands. git config --global alias.co checkout Simple, right? You can put global aliases in your user Git config file: ~/.gitconfig You can also put them in the config file for a given repository: project/.git/config Here's a list of mine.…
It's one of those rules that makes total sense the first time you here it. It's actually outlined concisely in the style guide: DO annotate with Object instead of dynamic to indicate any object is accepted. // **Use Object** // Accepts any object. void log(Object object) { print(object.toString()); } // **Use dynamic** // Only accepts bool or String, which can't be expressed in a type annotation.…
I'm getting into some non-trivial infrastructure and I wanted to put the word out. The story: The Observe package exposes ObservableList<E> , which works with Model Driven Views (mdv) to enable dynamic lists in your UI. This is all wrapped up with Polymer. I'd be nice to have a generic way to sort and filter an input list. CollectionView<E> wraps an ObservableList<E> with filter and sort…
Public service announcement for Dart developers, especially those publishing packages on Pub. Don't go crazy with noSuchMethod . noSuchMethod is kind of like QR codes. While funny, I think this goes a bit too far. I do think there are cases where QR codes are useful, but they are limited. Kinda' like noSuchMethod . Don't use noSuchMethod to be lazy I know! I'll use noSuchMethod to emulate getters…
tl;dr : Do your opining, ranting, lecturing, and quipping on your blog. Drop a link on Google+, Twitter, whatever. Don't grow your content in a walled garden. I spend my days swimming in a pool of Google's Kool-Aid: Chrome, Dart, Closure Compiler, Plus, Analytics, oh yeah, and Search. Util today, Google Reader (R.I.P.) was towards the top of that list. I'm now one of many jumping between a handful…
I asked Twitter nicely yesterday. The only response: I don't dislike writing bash scripts. I hate it. I also hate the lack of portability, as pointed out by +Daniel Steigerwald : Great idea, +Daniel Steigerwald , but why use NodeJS when I could use Dart? If you fetch the latest version of the Dart Bag-of-Tricks , you'll notice a new binary bin/bench . If you're running bash and dart is in your…
When writing any software, even for the web, I try to do as much testing as possible outside the browser. A lot of great testing can be done of algorithms, data models, and business logic without booting up Chrome. Node.js enabled this with Javascript. Dart has had an out-of-browser--read console--story since day one. But some things you must test in a browser. The Dart Bag of Tricks (BOT) has had…
tl;dr : Implementing features similar to Bootstrap is hard without basic animation support in Dart. Basic animation support is not as easy as you'd think. I've made a stab . Check out the demo . I've started a new Dart project - Dart Widgets . The inspiration is Bootstrap , but with a focus on features that map cleanly to Web Components . While digging into Bootstrap, I realized that there was a…
I noticed r15005 turns on more renaming in dart2js with --minify so I thought I'd see the impact on Pop, Pop, Win! The last time I did a build and deploy of PPW was on r14873. Here are the sizes of game.dart.js dart2js 617,201 bytes closure compiler 621.07KB gzip (via http) 107.7KB Notes: dart2js is running with the --minify flag I'm using the closure-compiler with default settings. Build from 17…
I've been busy the last few weeks. I've had to give more time to another gig, so I've slowed my progress on the Dartsweeper Pop, Pop, Win! But I've made some great tractions. Check out the demo at sweeper.j832.com . Graphics and animation with TexturePacker Graphics for the Pop, Pop Win! (PPW) are packaged using TexturePacker . TexturePacker takes a number of source images and produces an…
Looks can be deceiving Looks about the same as last time , right? The visuals and interaction were designed to be almost identical, but the plumbing is very different. The original, HTML DOM version used a table to render the game board. It's straight forward to let DOM elements handle layout and mouse interaction. Throw in a little CSS and you have a functional—albeit ugly—game. But if one wants…
Are you maintaining a legacy applications written in VB6? Windows Forms? Java? Are you relying on ActiveX and outdated browsers? Are you unsure how to support new devices, new form factors, and new platforms? Do you have a Web presence, but lack a Web mindset? Let's talk. As a consultant, I have had the opportunity to work on a lot of different projects and platforms. Big enterprise apps with…
tl;dr : I'm building a version of Minesweeper in Dart as an example of something straight-forward and fun. I hope to show how to build Dart apps and demonstrate why Dart is a great tool for building web experiences. Play it here . Check out the code on Github . Watch my blog for updates in the next few weeks. Intro I'm having a lot of fun with Dart. It's a great intersection of the things I love…
I've ported the QR Code logic from my pl javascript library into dartlib . I don't have funky animations yet, but: The QR Code is generated off-thread using isolates. It compiles to Javascript. ~9,000 lines worth. The JS version seems to work fine in Chrome, but not Firefox or Safari. The conversion was pretty straight forward. Types in Dart make debugging this type of code so much easier.…
tl;dr : Go to this form and donate $20 to an amazing cause . Show up at Office Nomads on Thursday, Feb 23 at 6:30pm. Learn Git . What : a workshop to get people productive with Git. Why: Git is an amazing tool to manage and collaborate on text content -- source code, html, javascript, etc. Giving money to United Republic is a great way to get involved in the political process and fight the…
tl;dr : Fill out this form . Contribute to a great cause . Learn that thing you've been putting off. A year and change ago I did a Getting Git workshop at my coworker spot in Seattle, Office Nomads . Getting bootstrapped--self-sufficient--on new technologies is tough, especially if you don't have a good relationship with someone experienced. Conferences and user groups can be intimidating and…
My main gig has been all Silverlight all the time over the last many moons. I've pushed a lot of changes to the Bag 'o Tricks in response. I've also added the BOT to NuGet . Here's a lazy man's update--just a copy-paste from the changelog . Take a look. Bag of Tricks Change Log V4.1.0 - 2011-07-20 Lot's of fun now stuff, but no breaking changes! Feels good. Added GetStringComparer extension that…
I'm know I could have done this by hand way faster than it took me to figure out. I’m sure there are better ways to do this than I figured out below. But still enjoyed figuring it out. Scenario: Uninstall all gems with version 3.0.0.beta4. These map to one of the last Rails 3 betas. …and do it in one bash command. This is what I ended up with. gem list | grep beta4 | awk '{print $1}' | xargs gem…
I’m a big believer in DRY – Don’t Repeat Yourself – in software. While I try hard to practice this in the code for the Bag of Tricks (BOT), until recently I’ve ignored my project files. VS handles that, right? Well, kind. It turns out there is a lot of duplication in proj files. Every one defines constants and output paths. If you’re using Code Contracts, you get a bunch of contract properties all…
On October 7, I updated the Bag of Tricks CodePlex site : Active development for BOT has moved to GitHub . Don’t Panic! (You can still use Subversion) I’m super happy folks like using the BOT. I don’t want to stop you. You can still download the source as a zip. Just click download on the GitHub page . And you can still use Subversion (SVN). GitHub has done the wonderful work of enabling SVN via…
Back in the old days (sometime in 2005) I built out the Bag of Tricks. At the time, the index of the samples was stored in an XML file. I then used data binding to to connect to the XML, show the items and the descriptions, navigate to the page URLs. It was very cool…kinda… Then MEF came along and I realized that having a secondary list of each demo was a bit broken. Each demo should describe…
Update: RSVP here . I love git . Really, really love git . I’ve used SVN and PerForce. They don’t come close. Some folks here at Office Nomads have asked me to give a talk. I figured I’d open it up to the public. Details : Location : Office Nomads , 2nd Floor, 1617 Boylston, Seattle . When : Noon to 2pm, October 5, 2010 Cost : Proof of a $25 donation to EFF or Fix Congress First . (If you’re tight…
I don't have a lot of time to write, since I'm actually at the launch event, but I wanted to share a quick note about the plumbing of Agent 8 Ball. Check out http://box2d.thinkpixellab.com/ to see how we made our pool game come alive.
Last weekend I tweeted: My weekend #ruby hacking. GraphViz for your #rails Gemfile using @gembundler. http://bit.ly/b1PaXT Suggestions, patches welcome! What a fun week it's been. @wycats hunted me down and asked if I'd roll bundle_view into bundler. Update: Made it into bundler. See the commits here .
Miguel blogged a great idea today, expanding on Joe Hewitt’s simple statement on Twitter : If CLI was the ECMA standard baked into browsers instead of ECMAScript we'd have a much more flexible web. Agreed. I’d love to be able to run C# instead of Javascript on my web page. I’d also love to be able to run Ruby. Or even Scala . So why not JVM on the Web? What about Go ? Why not indeed. If there is…
Has it really been two years since the last official update of the Bag of Tricks ? I guess it has. A lot has changed since then. I started my own consulting company. And then joined up with Robby to launch Pixel Lab . With previous releases, I was doing a very good job of breaking out almost all of the changes. This time, there are just too many. I’ll try to highlight the big ones. Added Org Tree.…
What is Native Client? Have you heard of Native Client (NaCl) from Google? Yet another open-source client software play from our overlords in Mountainview. The write-up on the project site is pretty good: Native Client is an open-source technology for running native code in web applications, with the goal of maintaining the browser neutrality, OS portability, and safety that people expect from web…
We’d all like a peek inside the mind of Eric Schmidt —beyond just understanding what he’s wearing in his twitter profile picture . Search and maps and profiles: these all make sense. But there are a set projects that Google has been putting out lately that don't fit. They're open source and focused on the client machine. A browser . An operating system . An extension to HTTP - SPDY . An drastic…