MoOx / pjax

Easily enable fast Ajax navigation on any website (using pushState + xhr)
MIT License
1.46k stars 125 forks source link

Change way to handle .isSupported #18

Closed MoOx closed 6 years ago

MoOx commented 10 years ago

Currently the way things are (shitty) done, the trick to "mock" api for unsupported browser is awful cause you can for eg use Pjax.switches.blah. After refactor on testling branch, I need to do something else. Like just add a .isSupported method & document the fact that every call & ref usages should be prefixed by this test ?

BehindTheMath commented 6 years ago

@MoOx Do we still need to support browsers that don't support the History API? According to caniuse, nearly 95% of browsers in use support it.

In my opinion, we should just have 1 check for isSupported() in the constructor before doing anything, and then make the user responsible for implementing a fallback.

MoOx commented 6 years ago

2014, I guess we can just forget this.