<story><title>Routable, an in-app URL router for iOS and Android</title><url>http://usepropeller.com/blog/posts/routable</url></story><parent_chain></parent_chain><comment><author>realrocker</author><text>Very cool. But please don&apos;t use it. The de-facto architecture design proposed by the Android team is to use fragments for view separation. In my own app development workflow, I have not used multiple activity design for a really long time now. This is what you lose with external routing:
1. Better multiple screen size support: By housing all the fragments in one activity, you have control to hide/show/re-size fragments according to need since you have now have the fragment stack data in one activity. An external router doesn&apos;t make sense now, since the internal routing would still need to be handled by the activity. And if you write a router even for the internal stuff, then you need to address other concerns such as: backstack and bundles.
2. Single Top Activities: The Android app stack may have multiple instances of the same activity. When you route with a data path (user/id/1) which activity are you referring to? The Intent and PendingIntent classes have been developed over the years to face such weird idiosyncrasies of the platform.
3. Action Modes: The action mode api helps to create contextual actions. It gives you a nice separation of concern through callbacks. This glues the activity with fragments well. In two calls you setup a fragment and its contextual menus. With external routing you lose that or you handle it with more glue code.&lt;p&gt;I agree there are some cosmetic advantages through external routing, but develop any non-trivial Android app and you will find out, it&apos;s not always a good idea to fight the framework. In some cases maybe it is, for e.g this cool project: &lt;a href=&quot;https://github.com/mitmel/SimpleContentProvider&quot; rel=&quot;nofollow&quot;&gt;https://github.com/mitmel/SimpleContentProvider&lt;/a&gt;.
Java is already too verbose. Wiring an external router means 
handling a lot of concerns yourself. Not cool.</text></comment>
<story><title>Routable, an in-app URL router for iOS and Android</title><url>http://usepropeller.com/blog/posts/routable</url></story><parent_chain></parent_chain><comment><author>rogerbinns</author><text>What exactly is wrong with using Intents in Android?  They would seem to be a far better mechanism for Android code, and also interoperate with the rest of the system (eg notifications).</text></comment>