How to use the current-device.default.ios function in current-device

To help you get started, we’ve selected a few current-device examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github caiobiodere / cordova-template-framework7-vue-webpack / template_src / webpack / dev_helpers / CordovaDeviceRouter.js View on Github external
script = document.createElement("script");

  script.onload = function () {
    console.log("Cordova script loaded!");
  };

  script.src = `platform_cordova_files/${platform}/cordova.js`;
  body.appendChild(script);


  console.log(`${platform} platform cordova.js injected.`);
}

if (deviceJs.android())
  bodyPrepend("android");
else if (deviceJs.ios())
  bodyPrepend("ios");
else
  bodyPrepend("browser");

current-device

The easiest way to write conditional CSS and/or JavaScript based on device operating system (iOS, Android, Blackberry, Windows, Firefox OS, MeeGo, AppleTV, etc), orientation (Portrait vs. Landscape), and type (Tablet vs. Mobile).

MIT
Latest version published 4 years ago

Package Health Score

64 / 100
Full package analysis