Skip to content

Instantly share code, notes, and snippets.

@EddyVerbruggen
Last active June 14, 2017 07:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save EddyVerbruggen/82465c796b857539b2da131cbd64f46f to your computer and use it in GitHub Desktop.
Save EddyVerbruggen/82465c796b857539b2da131cbd64f46f to your computer and use it in GitHub Desktop.
Determine running on a tablet in NativeScript
// required imports:
import { DeviceType } from "ui/enums";
import { device } from "platform";
// then wherever you need it:
const isTablet: boolean = device.deviceType === DeviceType.Tablet;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment