1. #1
    Sencha Premium Member
    Join Date
    Apr 2008
    Posts
    248
    Vote Rating
    24
    themightychris will become famous soon enough themightychris will become famous soon enough

      0  

    Default ST2-style routes for controllers

    ST2-style routes for controllers


    Here's a clean override that implements the routes config and redirectTo() method into controllers for ExtJS. It's compatible with the same syntax used in Sencha Touch but with one extra app-level option (see below) for efficient ExtJS initial rendering. I was able to do it with a lot less code than ST2 uses by weeding out all the ST1 routing artifacts littering it.

    https://github.com/JarvusInnovations...llerRouting.js

    Download locally or use right off GitHub:
    Code:
    Ext.application({
        requires: [
            'Jarvus.ext.override.app.ControllerRouting'
        ],
        paths: {
            Jarvus: 'https://raw.github.com/JarvusInnovations/ext-library/master/Jarvus'
        },
    
        suspendLayoutUntilInitialRoute: true, // true to suspend layouts during app startup until initial route is handled
        ...
    });
    Chief Architect @ Jarv.us Innovations
    Co-captain @ Code for Philly
    Co-founder @ Devnuts - Philadelphia Hackerspace

  2. #2
    Sencha - Support Team slemmon's Avatar
    Join Date
    Mar 2009
    Location
    Boise, ID
    Posts
    5,032
    Vote Rating
    185
    slemmon is a splendid one to behold slemmon is a splendid one to behold slemmon is a splendid one to behold slemmon is a splendid one to behold slemmon is a splendid one to behold slemmon is a splendid one to behold slemmon is a splendid one to behold slemmon is a splendid one to behold

      0  

    Default


    Thanks for sharing!
    Are you a Sencha products veteran who has wondered what it might be like to work at Sencha? If so, please reach out to our recruiting manager: sheryl@sencha.com

    C
    heck out all of the 2013 SenchaCon presentations here:
    http://www.sencha.com/blog/senchacon...now-available/

Thread Participants: 1