wip
This commit is contained in:
parent
dc6a53e38c
commit
587136a82d
11 changed files with 90 additions and 14 deletions
|
@ -1,6 +1,7 @@
|
|||
import * as React from 'react';
|
||||
import * as ReactDOM from 'react-dom';
|
||||
import { App } from './App';
|
||||
import { LOCALSTORAGE_KEY_TOKEN } from './const';
|
||||
|
||||
document.body.classList.add('dark');
|
||||
|
||||
|
@ -11,7 +12,7 @@ const token = document.cookie
|
|||
?.split('=')[1];
|
||||
|
||||
if (token) {
|
||||
localStorage['token'] = token;
|
||||
localStorage[LOCALSTORAGE_KEY_TOKEN] = token;
|
||||
// 今の所はcookieをトークン以外に使用しないため全消去する
|
||||
// もしcookieの用途が増えるのであればここを良い感じに書き直す必要がある
|
||||
document.cookie = '';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue