aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps/settings/routes.js
diff options
context:
space:
mode:
authorStas Vilchik <stas.vilchik@sonarsource.com>2017-07-18 15:11:50 +0200
committerGitHub <noreply@github.com>2017-07-18 15:11:50 +0200
commitf42aaaa98952fa997665dfbe29515eb993e67701 (patch)
tree871b4771a6354d5a2e52f20e82914eae2e1f2420 /server/sonar-web/src/main/js/apps/settings/routes.js
parentf3c05bcc9a63fd20dafe0411490265103b599179 (diff)
downloadsonarqube-f42aaaa98952fa997665dfbe29515eb993e67701.tar.gz
sonarqube-f42aaaa98952fa997665dfbe29515eb993e67701.zip
replace require.ensure with dymamic import (#2187)
Diffstat (limited to 'server/sonar-web/src/main/js/apps/settings/routes.js')
-rw-r--r--server/sonar-web/src/main/js/apps/settings/routes.js16
1 files changed, 4 insertions, 12 deletions
diff --git a/server/sonar-web/src/main/js/apps/settings/routes.js b/server/sonar-web/src/main/js/apps/settings/routes.js
index 68300e6d2c8..9a408f19fe8 100644
--- a/server/sonar-web/src/main/js/apps/settings/routes.js
+++ b/server/sonar-web/src/main/js/apps/settings/routes.js
@@ -20,33 +20,25 @@
const routes = [
{
getIndexRoute(_, callback) {
- require.ensure([], require => {
- callback(null, { component: require('./components/AppContainer').default });
- });
+ import('./components/AppContainer').then(i => callback(null, { component: i.default }));
}
},
{
path: 'licenses',
getComponent(_, callback) {
- require.ensure([], require => {
- callback(null, require('./licenses/LicensesApp').default);
- });
+ import('./licenses/LicensesApp').then(i => callback(null, i.default));
}
},
{
path: 'encryption',
getComponent(_, callback) {
- require.ensure([], require => {
- callback(null, require('./encryption/EncryptionAppContainer').default);
- });
+ import('./encryption/EncryptionAppContainer').then(i => callback(null, i.default));
}
},
{
path: 'server_id',
getComponent(_, callback) {
- require.ensure([], require => {
- callback(null, require('./serverId/ServerIdAppContainer').default);
- });
+ import('./serverId/ServerIdAppContainer').then(i => callback(null, i.default));
}
}
];