sammy.js - Pass the request to server sammyjs -
new sammyjs. broadly have 2 modules, 1 server side rendered , de-coupled client app. have implemented ko , sammy , working good. requests, need pass on server. possible sammy?
sammy(function () { this.get( ".*", function () { var view = window.location.pathname; if( view == "/" ) appviewmodel.currentview( "home-page" ); else if( view == "/product" ) appviewmodel.currentview( "product-page" ); else if( view == "/admin" ) return false; // ssr page }); }).run();
the answer turned out simple, don't capture request in first place.
this.get( "^(?!\/admin$).*$", function() { // });
Comments
Post a Comment