Skip to content

Commit

Permalink
Merge pull request #1268 from marmelab/Use-Lodash-instead-of-underscore
Browse files Browse the repository at this point in the history
Use lodash instead of underscore
  • Loading branch information
Kmaschta authored Dec 9, 2016
2 parents 49fdc56 + 951f276 commit db3d9dd
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@
"rangy": "^1.3.0",
"restangular": "~1.5.2",
"textangular": "1.4.3",
"ui-select": "0.18.1",
"underscore": "^1.8.3"
"ui-select": "0.18.1"
},
"devDependencies": {
"angular-mocks": "~1.4.8",
Expand Down Expand Up @@ -68,6 +67,8 @@
"karma-ng-scenario": "~0.1.0",
"karma-phantomjs-launcher": "~1.0.0",
"karma-webpack": "~1.7.0",
"lodash": "^4.17.2",
"lodash.debounce": "4.0.8",
"mocha": "^2.1.0",
"ng-annotate-loader": "0.0.2",
"ngtemplate-loader": "^1.3.0",
Expand Down
4 changes: 2 additions & 2 deletions src/javascripts/ng-admin/Crud/list/ListLayoutController.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* globals _ */
const debounce = require('lodash.debounce');

export default class ListLayoutController {
constructor($scope, $stateParams, $state, $location, $timeout, view, dataStore) {
Expand Down Expand Up @@ -34,7 +34,7 @@ export default class ListLayoutController {
// apply filters when filter values change
$scope.$watch(
() => this.search,
_.debounce((newValues, oldValues) => {
debounce((newValues, oldValues) => {
if (newValues != oldValues) {
this.updateFilters();
}
Expand Down
2 changes: 1 addition & 1 deletion src/javascripts/vendors.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ require('angular-numeraljs');
require('angular-ui-bootstrap/dist/ui-bootstrap-tpls');
require('ng-file-upload');

global._ = require('underscore');
global._ = require('lodash');

0 comments on commit db3d9dd

Please sign in to comment.