Announcing The Iron Router Update
When we set out to write Discover Meteor, we knew we were signing up for a long-term job. Meteor evolves at a rapid pace, so from the start we promised to update the book and keep up with the changes.
Cyber Monday Deal: 20% Off!
Before we talk more about the update, a special announcement: to celebrate the new update as well as Cyber Monday, we’re holding a special 20% off sale on all book packages!
Simply visit this special URL to unlock the discount, and it will then automatically be applied when you buy the book:
(If you’ve already bought the book and would like to upgrade, look in your inbox for special email discount codes!)
A Long Process
The update wasn’t that simple though. Tom and Chris were hard at work on improving the package even after the initial release, so we couldn’t start rewriting the book until the API stabilized.
So in the meantime, I decided to get to work implementing Iron Router in Telescope, the open-source Meteor app that inspired the book in the first place.
This turned out to be a much bigger task than I originally anticipated, taking up a good month or nearly full-time work. Not only did we change the way routing and pagination worked, but we also refactored the whole publication/subscription model of the app to take advantage of the new Iron Router features.
But in the end, it was worth it since we put everything we learned in the updated version of the book.
A New Structure
Switching to Iron Router had a major impact on Microscope, the app that we build throughout the book. We rewrote the Routing and Pagination chapters from scratch and were also able to drastically simplify other parts of the book, getting rid of all Session variables and
autorun blocks in the process.
And as you’ll also see in the book, Iron Router’s big advantage is not its routing features, but the added structure it brings to your app.
While it’s true that Meteor’s freeform structure has its advantages, it’s also good to have some kind of basic convention on how to architecture your apps, and that’s exactly what Iron Router brings to the table.
You’ll find a full changelog in the member’s area.
The amazing thing about the Meteor ecosystem is just how fast it’s improving. New packages are coming out every day, and the Meteor folks themselves are hitting milestones at an increasing pace in prevision of the big 1.0 release. Of course, it makes our job a bit harder, but it also makes it a lot more fun!
Now let’s just hope we can get a few weeks of breathing room before the Meteor UI update drops and we have to rewrite the whole thing again…