Backbone supplies structure to JavaScript-heavy applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing application over a RESTful JSON interface.
iloveyou

Backbone.js的兼容性怎么样?ie6能支持吗

  •  
  •   iloveyou · May 29, 2013 · 12392 views
    This topic created in 4750 days ago, the information mentioned may be changed or developed.
    6 replies    1970-01-01 08:00:00 +08:00
    meteor
        1
    meteor  
       May 29, 2013   ❤️ 1
    自己测试下吧.
    http://backbonejs.org/test/
    用backbone和jquery不是干同一样工作的.
    otakustay
        2
    otakustay  
       May 29, 2013   ❤️ 1
    backbone几乎和任何界面、DOM没有任何关系,就一系统基础框架管一堆普通的对象,兼容性上不是问题
    YuHong
        3
    YuHong  
       May 29, 2013 via iPhone   ❤️ 1
    router用到hashChange,history用到hashState,Backbone.localstorage 这些肯定不支持。
    dom的操作依赖jQuery没问题,Zepto不行。
    underscore的方法应该没问题。
    还真没在IE6上用过,用上backbone为啥还用考虑IE6?
    kangjia
        4
    kangjia  
       May 30, 2013   ❤️ 1
    IE6可以用。 router是使用的setInterval来监听的hash
    iloveyou
        5
    iloveyou  
    OP
       May 30, 2013
    @YuHong 我其实不是做单页程序,只是需要做个很复杂的js组件,我想用mvc的方式开发维护容易
    freestyle21
        6
    freestyle21  
       Mar 4, 2014
    @kangjia 正解。如果支持pushState绑定popstate事件;支持onhasChange绑定hashChange;最后不行就setInterval.
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3777 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 96821589 · 36ms · UTC 04:33 · PVG 12:33 · LAX 21:33 · JFK 00:33
    ♥ Do have faith in what you're doing.