Skip to content

Instantly share code, notes, and snippets.

🌞 Morning 74 commits █▉░░░░░░░░░░░░░░░░░░░ 9.1%
🌆 Daytime 211 commits █████▍░░░░░░░░░░░░░░░ 26.0%
🌃 Evening 359 commits █████████▎░░░░░░░░░░░ 44.3%
🌙 Night 167 commits ████▎░░░░░░░░░░░░░░░░ 20.6%
@HyunGyu-Lee
HyunGyu-Lee / firebase.js
Created December 2, 2019 06:46
Firebase 모듈 초기화
import Vue from 'vue'
import { firestorePlugin } from 'vuefire'
import firebase from 'firebase/app'
import 'firebase/firestore'
Vue.use(firestorePlugin)
var firebaseConfig = {
apiKey: "AIzaSyDzqN-wqvAsZ41HVCTzHYqqpQ_cX1sWzYs",
authDomain: "daily-todo-backend.firebaseapp.com",
@HyunGyu-Lee
HyunGyu-Lee / auth.js
Created November 29, 2019 01:29
Vue 토큰 저장
import axios from 'axios'
import store from '@/plugins/store'
axios.interceptors.request.use((config) => {
let accessToken = store.getters.accessToken;
if (accessToken) {
config.headers.Authorization = `Bearer ${accessToken}`;
}
return config;
});