mirror of
https://github.com/uetchy/namae.git
synced 2025-10-14 23:22:19 +09:00
prettier
This commit is contained in:
@@ -4,7 +4,7 @@ import 'rc-tooltip/assets/bootstrap.css';
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
import { Router } from 'react-router-dom';
|
||||
import { toast, ToastContainer } from 'react-toastify';
|
||||
import { ToastContainer } from 'react-toastify';
|
||||
import 'react-toastify/dist/ReactToastify.css';
|
||||
import App from './App';
|
||||
import * as serviceWorker from './serviceWorker';
|
||||
@@ -36,21 +36,23 @@ ReactDOM.render(
|
||||
document.getElementById('root'),
|
||||
);
|
||||
|
||||
serviceWorker.register({
|
||||
onUpdate: (registration) => {
|
||||
console.log('Update available');
|
||||
serviceWorker.unregister();
|
||||
// TODO: gracefully update service worker
|
||||
// serviceWorker.register({
|
||||
// onUpdate: (registration) => {
|
||||
// console.log('Update available');
|
||||
|
||||
toast.dark('New version available! Click here to update.', {
|
||||
onClose: () => {
|
||||
window.location.reload();
|
||||
},
|
||||
position: 'top-right',
|
||||
autoClose: false,
|
||||
closeButton: false,
|
||||
closeOnClick: true,
|
||||
});
|
||||
if (registration && registration.waiting) {
|
||||
registration.waiting.postMessage({ type: 'SKIP_WAITING' });
|
||||
}
|
||||
},
|
||||
});
|
||||
// toast.dark('New version available! Click here to update.', {
|
||||
// onClose: () => {
|
||||
// window.location.reload();
|
||||
// },
|
||||
// position: 'top-right',
|
||||
// autoClose: false,
|
||||
// closeButton: false,
|
||||
// closeOnClick: true,
|
||||
// });
|
||||
// if (registration && registration.waiting) {
|
||||
// registration.waiting.postMessage({ type: 'SKIP_WAITING' });
|
||||
// }
|
||||
// },
|
||||
// });
|
||||
|
@@ -1,5 +1,5 @@
|
||||
import {History} from 'history';
|
||||
import {action, createTypedHooks, Action, createStore} from 'easy-peasy';
|
||||
import { action, Action, createStore, createTypedHooks } from 'easy-peasy';
|
||||
import { History } from 'history';
|
||||
|
||||
interface StatsModel {
|
||||
availableCount: number;
|
||||
|
Reference in New Issue
Block a user