mirror of
https://github.com/simon987/sist2.git
synced 2025-12-18 09:49:06 +00:00
Add support for auth0
This commit is contained in:
@@ -3,16 +3,32 @@ import 'mutationobserver-shim'
|
||||
import Vue from 'vue'
|
||||
import './plugins/bootstrap-vue'
|
||||
import App from './App.vue'
|
||||
import router from './router'
|
||||
import router, {setUseAuth0} from './router'
|
||||
import store from './store'
|
||||
import VueI18n from "vue-i18n";
|
||||
import messages from "@/i18n/messages";
|
||||
|
||||
import { Auth0Plugin } from './plugins/auth0';
|
||||
|
||||
import VueRouter from "vue-router";
|
||||
|
||||
Vue.config.productionTip = false;
|
||||
|
||||
export function setupAuth0(domain, clientId, audience) {
|
||||
|
||||
setUseAuth0(true);
|
||||
|
||||
Vue.use(Auth0Plugin, {
|
||||
domain,
|
||||
clientId,
|
||||
audience,
|
||||
onRedirectCallback: appState => {}
|
||||
});
|
||||
}
|
||||
|
||||
Vue.prototype.$auth = null;
|
||||
|
||||
Vue.config.productionTip = false;
|
||||
|
||||
Vue.use(VueI18n);
|
||||
Vue.use(VueRouter);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user