1.0.0 • Published 7 years ago

angular-sundial v1.0.0

Weekly downloads
4
License
MIT
Repository
github
Last release
7 years ago

Angular Sundial

A simple angular service that enhances the date object functionality of javascript to provide a more easy and robust api for getting the date and time

Installation

  1. Download this and extract it to your project folder
  2. Make sure to include angular.js and angular-sundial.js to your index page

    <script src="angular.js"></script>
    <script src="angular-sundial.js"></script>
  3. Add the ngDraggable module to your main angular module

    angular.module('myApp', ['ngSundial']);

Demo

After installation, just open the index.html to view the demo page

Usage

Just inject the sundial service in your controller and call the available apis

app.controller('MainController', function (sundial) {
  var date = "Oct 30, 2016 11:15 PM";
  console.log('Date:', sundial.getDate(date));
});

TODO

  • API Documentation
  • Unit test