by rajivnarayana | v0.1.2
A nativescript api for TimePickerSlider cocoapods ios control
npm i --save nativescript-timepicker-slider
  • Version: 0.1.2
  • GitHub:
  • Downloads:
    • Last Day:   0
    • Last Week:  0
    • Last Month: 0

NativeScript date picker slider plugin

A plugin that enables you to use the cocoapod at in your native script app.


Run the following command from the root of your project

$ tns plugin add

This command automatically install the necessary ios files from the cocoapod github repository and adds as a dependency in your package.json file


There is an sample application at the folder "Example". To run it (assuming you have nativescript plugin installed globally)

$ sudo npm install typescript -g
$ tsc
$ cd Example
$ tns plugin add ../

Run the application from your mac onto your iOS simulator by typing

$ tns emulate ios --device=iPhone\ 5s

The following code from Example/app/main.xml show you a way to add Time picker to your layout

<Page xmlns="" loaded="pageLoaded" xmlns:tools="nativescript-timepicker-slider">
<DockLayout stretchLastChild="false" style="background-color: gray">


Following code from Exaple/app/main.js shows a way to listen to value changes

function onSliderLoaded(args) {
var slider = args.object;
slider.on(observableModule.Observable.propertyChangeEvent, (args) => {
if (args.propertyName == {
console.log('Do something with the data '+slider.value);
}, this);

exports.onSliderLoaded = onSliderLoaded;