angular-sliding-tags
v1.0.4
Published
Sliding tags in angular way
Downloads
7
Readme
angular-sliding-tags
Source from: sliding tags (Thanks to Thibaut). Learn its style and implement it with a input in angular way
Prerequisites
angularjs
Installation
You can install this package either with npm
or with bower
.
npm
npm install angular-sliding-tags
Then add a <script>
and <link>
to your index.html
:
<link rel="stylesheet" href="/node_modules/angular-sliding-tags/dist/css/sliding-tags.css">
<script src="/node_modules/angular-sliding-tags/dist/js/sliding-tags-input.js"></script>
bower
bower install angular-sliding-tags
Then add a <script>
and <link>
to your index.html
:
<link rel="stylesheet" href="/bower_components/angular-sliding-tags/dist/css/sliding-tags.css">
<script src="/bower_components/angular-sliding-tags/dist/js/sliding-tags-input.js"></script>
Include the module in app
var app = angular.module('app', ['sliding.tags']);
Usage
Declare your model with attributes name
and count
in your controller. For example:
$scope.tags = [
{name: 'example', count: 0}
]
Then add a <sliding-tags-input ng-model='tags'></sliding-tags-input>
to your <body>
with nd-model
Contributing
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D