angular-slug
Advanced tools
Comparing version 0.0.3 to 0.0.4
@@ -7,14 +7,21 @@ /** | ||
angular.module('slug', []) | ||
(function() { | ||
'use strict'; | ||
angular.module('slug', []) | ||
.provider('slug', slugProvider) | ||
.filter('slug', slugFilter); | ||
slugProvider.$inject = []; | ||
slugFilter.$inject = ['slug']; | ||
/** | ||
* Simple slug wrapper as provider. | ||
*/ | ||
.provider('slug', function () { | ||
slug.$get = function () { | ||
function slugProvider() { | ||
slug.$get = function() { | ||
return slug; | ||
} | ||
return slug; | ||
}) | ||
} | ||
@@ -24,4 +31,6 @@ /** | ||
*/ | ||
.filter('slug', function (slug) { | ||
function slugFilter(slug) { | ||
return slug; | ||
}); | ||
} | ||
})(); |
{ | ||
"name": "angular-slug", | ||
"main": "angular-slug.js", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"authors": [ | ||
@@ -25,5 +25,5 @@ "Lucas Constantino Silva" | ||
"dependencies": { | ||
"slug": "~0.8.0", | ||
"angular": "~1.3.15" | ||
"slug": "~0.9.1", | ||
"angular": "~1.5.7" | ||
} | ||
} |
{ | ||
"name": "angular-slug", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"repository": "lucasconstantino/angular-slug", | ||
"description": "An AngularJS wrapper arround the slug library", | ||
@@ -13,5 +14,5 @@ "main": "angular-slug.js", | ||
"dependencies": { | ||
"angular": "^1.3.15", | ||
"slug": "^0.8.0" | ||
"angular": "^1.5.7", | ||
"slug": "^0.9.1" | ||
} | ||
} |
@@ -1,4 +0,7 @@ | ||
Angular Slug | ||
============ | ||
[![GitHub version](https://badge.fury.io/gh/lucasconstantino%2Fangular-slug.svg)](https://badge.fury.io/gh/lucasconstantino%2Fangular-slug) | ||
[![npm version](https://badge.fury.io/js/angular-slug.svg)](http://badge.fury.io/js/angular-slug) | ||
[![Dependency Status](https://david-dm.org/lucasconstantino/angular-slug.svg)](https://david-dm.org/lucasconstantino/angular-slug) | ||
# Angular Slug | ||
> An AngularJS wrapper arround the [slug](https://www.npmjs.com/package/slug) library. Simple as that. | ||
@@ -8,2 +11,14 @@ | ||
## Installation | ||
**via Bower:** | ||
``` | ||
bower install angular-slug --save | ||
``` | ||
**via npm:** | ||
``` | ||
npm install angular-slug --save | ||
``` | ||
## Usage | ||
@@ -26,2 +41,3 @@ | ||
We expose the slug service in the provider phase as the library itself. It makes it easy to define new modes and/or modify any char replacements before the application start: | ||
``` | ||
@@ -36,3 +52,3 @@ module.config('slugProvider', function (slugProvider) { | ||
}); | ||
``` | ||
``` | ||
@@ -42,2 +58,3 @@ ### Execution Options | ||
The filter directly uses the service to transform the string. The service, in turn, is the actual slug library as is and accepts [any argument that the library accepts](https://www.npmjs.com/package/slug#options). For instance, to modify the replacement char at a slug execution, you can do as follows: | ||
``` | ||
@@ -47,3 +64,3 @@ module.controller('MyCtrl', function (slug) { | ||
}); | ||
``` | ||
``` | ||
@@ -50,0 +67,0 @@ ## License |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
85
1
2
5516
5
56
+ Addedslug@0.9.4(transitive)
- Removedslug@0.8.0(transitive)
Updatedangular@^1.5.7
Updatedslug@^0.9.1