mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-08-09 13:55:01 +02:00
Enable the Vue 3 front-end
This commit is contained in:
21
resources/js/services/authService.js
vendored
Normal file
21
resources/js/services/authService.js
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
import { httpClientFactory } from '@/services/httpClientFactory'
|
||||
|
||||
const webClient = httpClientFactory('web')
|
||||
const apiClient = httpClientFactory('api')
|
||||
|
||||
export default {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
logout(config = {}) {
|
||||
return webClient.get('/user/logout', { ...config })
|
||||
},
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
async getCurrentUser(config = {}) {
|
||||
return apiClient.get('/user', { ...config })
|
||||
},
|
||||
|
||||
}
|
Reference in New Issue
Block a user