Skip to content

Commit

Permalink
Added: usage of setLocale api
Browse files Browse the repository at this point in the history
  • Loading branch information
R-Sourabh committed Mar 22, 2024
1 parent 38c4b7e commit feed070
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/adapter/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { api, client, getConfig, init, initialise, logout, resetConfig, updateInstanceUrl, updateToken } from '@hotwax/oms-api'
import { api, client, getConfig, init, initialise, logout, resetConfig, updateInstanceUrl, updateToken, setUserLocale } from '@hotwax/oms-api'

export {
api,
Expand All @@ -9,5 +9,6 @@ export {
logout,
resetConfig,
updateInstanceUrl,
updateToken
updateToken,
setUserLocale
}
5 changes: 3 additions & 2 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import permissionRules from '@/authorization/Rules';
import permissionActions from '@/authorization/Actions';
import { dxpComponents } from '@hotwax/dxp-components'
import { login, logout, loader } from './user-utils';
import { getConfig, initialise } from '@/adapter'
import { getConfig, initialise, setUserLocale } from '@/adapter'
import localeMessages from './locales';


Expand All @@ -60,7 +60,8 @@ const app = createApp(App)
appLoginUrl: process.env.VUE_APP_LOGIN_URL as string,
getConfig,
initialise,
localeMessages
localeMessages,
setUserLocale
});

// Filters are removed in Vue 3 and global filter introduced https://v3.vuejs.org/guide/migration/filters.html#global-filters
Expand Down

0 comments on commit feed070

Please sign in to comment.