aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps/groups
diff options
context:
space:
mode:
Diffstat (limited to 'server/sonar-web/src/main/js/apps/groups')
-rw-r--r--server/sonar-web/src/main/js/apps/groups/group.js3
-rw-r--r--server/sonar-web/src/main/js/apps/groups/routes.js18
-rw-r--r--server/sonar-web/src/main/js/apps/groups/search-view.js2
3 files changed, 15 insertions, 8 deletions
diff --git a/server/sonar-web/src/main/js/apps/groups/group.js b/server/sonar-web/src/main/js/apps/groups/group.js
index a6a0d587a19..4ca0a08d98e 100644
--- a/server/sonar-web/src/main/js/apps/groups/group.js
+++ b/server/sonar-web/src/main/js/apps/groups/group.js
@@ -17,8 +17,7 @@
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
-import defaults from 'lodash/defaults';
-import pick from 'lodash/pick';
+import { defaults, pick } from 'lodash';
import Backbone from 'backbone';
export default Backbone.Model.extend({
diff --git a/server/sonar-web/src/main/js/apps/groups/routes.js b/server/sonar-web/src/main/js/apps/groups/routes.js
index 682cb275dab..d161da9d9fe 100644
--- a/server/sonar-web/src/main/js/apps/groups/routes.js
+++ b/server/sonar-web/src/main/js/apps/groups/routes.js
@@ -17,9 +17,17 @@
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
-import React from 'react';
-import { IndexRoute } from 'react-router';
-import GroupsAppContainer from './components/GroupsAppContainer';
-import forSingleOrganization from '../organizations/forSingleOrganization';
+const routes = [
+ {
+ getIndexRoute(_, callback) {
+ require.ensure([], require => {
+ const GroupsAppContainer = require('./components/GroupsAppContainer').default;
+ const forSingleOrganization = require('../organizations/forSingleOrganization').default;
+ const component = forSingleOrganization(GroupsAppContainer);
+ callback(null, { component });
+ });
+ }
+ }
+];
-export default <IndexRoute component={forSingleOrganization(GroupsAppContainer)} />;
+export default routes;
diff --git a/server/sonar-web/src/main/js/apps/groups/search-view.js b/server/sonar-web/src/main/js/apps/groups/search-view.js
index 6c25de952a0..9acd7109e57 100644
--- a/server/sonar-web/src/main/js/apps/groups/search-view.js
+++ b/server/sonar-web/src/main/js/apps/groups/search-view.js
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
-import debounce from 'lodash/debounce';
+import { debounce } from 'lodash';
import Marionette from 'backbone.marionette';
import Template from './templates/groups-search.hbs';