Native AngularJS directive that displays a Prime Number table, which is a convenient way to visualize the prime number distribution.
#Dependencies
Requires:
- AngularJS 1.1.3 or higher (Not tested with 1.0.x)
#Setup and Testing We use karma, jshint, jscs, and istanbul to ensure the quality of the code. The easiest way to run these checks is to run these commands:
npm install -g gulp
npm install
npm test
The karma task will try to open Chrome as a browser in which to run the tests. Make sure this is available or change the configuration in test\test.config.js
#Dependencies We use bower for dependency management.
#Usage
dependencies: {
"angular-prime-directive": "latest"
}
To your bower.json file. Then run
bower install
This will copy the angular-prime-directive files into your components folder, along with its dependencies.
Load the script files in your application:
<script type="text/javascript" src="components/angular/angular.js"></script>
<script type="text/javascript" src="components/angular-prime-directive/src/js/primeDirective.js"></script>
<link rel="stylesheet" href="components/angular-prime-directive/src/css/primeDirective.css">
Add the date module as a dependency to your application module:
var myAppModule = angular.module('MyApp', ['ui.prime.directive'])
Apply the directive to your form elements:
<div data-prime-directive ></div>
None
angular-prime-directive is freely distributable under the terms of the MIT license.
Support this project and other work by Dale Lotts via gittip.