summaryrefslogtreecommitdiff
path: root/vue.config.js
diff options
context:
space:
mode:
authorYoshie Muranaka <yoshiemuranaka@gmail.com>2020-09-03 23:25:50 +0300
committerYoshie Muranaka <yoshiemuranaka@gmail.com>2020-09-17 01:47:38 +0300
commit0214fedb49c4fcae85be9f6e6c542932518a5ffc (patch)
tree1aadcb2767e4a21d8b19ff69b562a2eb0d1cdbc1 /vue.config.js
parent14717e338482cceb0f417d4af20a22fb165d6bc5 (diff)
downloadwebui-vue-0214fedb49c4fcae85be9f6e6c542932518a5ffc.tar.xz
Update config to enable custom app navigation
- Update documentation to include navigation customizations - Created an IBM specific application navigation file to demonstrate how to remove KVM navigation item Signed-off-by: Yoshie Muranaka <yoshiemuranaka@gmail.com> Change-Id: I2ea61e9f3a43e6821f274ed90e0eed18afabccb7
Diffstat (limited to 'vue.config.js')
-rw-r--r--vue.config.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/vue.config.js b/vue.config.js
index 1e17def0..53dc6141 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -55,6 +55,8 @@ module.exports = {
const envName = process.env.VUE_APP_ENV_NAME;
const hasCustomStore = process.env.CUSTOM_STORE === 'true' ? true : false;
const hasCustomRouter = process.env.CUSTOM_ROUTER === 'true' ? true : false;
+ const hasCustomAppNav =
+ process.env.CUSTOM_APP_NAV === 'true' ? true : false;
if (process.env.NODE_ENV === 'production') {
config.plugins.push(
@@ -73,6 +75,12 @@ module.exports = {
// If env has custom router, resolve router module in src/main.js
config.resolve.alias['./router$'] = `./env/router/${envName}.js`;
}
+ if (hasCustomAppNav) {
+ // If env has custom AppNavigation, resolve AppNavigationMixin module in src/components/AppNavigation/AppNavigation.vue
+ config.resolve.alias[
+ './AppNavigationMixin$'
+ ] = `@/env/components/AppNavigation/${envName}.js`;
+ }
}
},
chainWebpack: config => {