Skip to content

Commit

Permalink
Merge pull request #78 from gustavomazzoni/master
Browse files Browse the repository at this point in the history
Added Angular support with LZString as a Factory.
  • Loading branch information
pieroxy committed Jul 26, 2016
2 parents 94fc39a + c58a220 commit 86c3934
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions libs/lz-string.js
Original file line number Diff line number Diff line change
Expand Up @@ -498,4 +498,9 @@ if (typeof define === 'function' && define.amd) {
define(function () { return LZString; });
} else if( typeof module !== 'undefined' && module != null ) {
module.exports = LZString
} else if( typeof angular !== 'undefined' && angular != null ) {
angular.module('LZString', [])
.factory('LZString', function () {
return LZString;
});
}

0 comments on commit 86c3934

Please sign in to comment.