Last active
November 12, 2015 10:14
-
-
Save karlkori/c73409c2b8c49abe652d to your computer and use it in GitHub Desktop.
How use js libs in Angular
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* include js lib (lodash) before angular! */ | |
| 'use strict'; | |
| angular | |
| .module('app', []) | |
| .factory('_', ['$window', function($window) { | |
| return $window._; | |
| }]) | |
| .controller('MainCtrl', ['$scope', '_', | |
| function($scope, _) { | |
| } | |
| ]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment