Support

Framework7 also comes with features detection library.

It is available as a support property of Framework7 class (Framework7.support) and same property on initialized app instance (app.support):

  1. // If we need it in place where we don't have access to app instance or before we init the app
  2. if (!Framework7.support.touch) {
  3. console.log('No touch support');
  4. }
  5. // After we init the app we can access it as app instance property
  6. var app = new Framework7({ /*...*/ });
  7. if (!app.support.touch) {
  8. console.log('No touch support');
  9. }

Support Properties

touchTouch events support (touchstart, touchmove, touchend)
transforms3dCSS 3D Transforms support
flexboxCSS Flexbox model support
observerMutation Observers support
passiveListenerPassive event listener support
gesturesGestures event support (gesturestart, gesturechange, gestureend)

← Device

Plugins API →