Refreshing the current url in BackboneJS
I've been using BackboneJS for a short time but recently came up with a problem when I was trying to reload the current url. After looking for an answer I came up with a post by Eric Bae.
Backbone.history.loadUrl( Backbone.history.fragment )
What this line of code does is grab the history saved by the url and force to load it by passing it to the loadUrl method. This hacked has been working for me and I hope it works for you too.
Written by Edilberto Ruvalcaba
Related protips
1 Response
Thanks it was really helpful.
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Js
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#