1
0
mirror of https://github.com/uetchy/namae.git synced 2025-08-20 18:08:11 +09:00

feat: add uniqueness indicator

This commit is contained in:
2020-03-26 20:22:06 +09:00
parent 2f85792fce
commit ef24e724d8
13 changed files with 297 additions and 48 deletions

View File

@@ -1,11 +1,10 @@
import ReactGA from 'react-ga';
import * as Sentry from '@sentry/browser';
import {createBrowserHistory} from 'history';
import {History} from 'history';
const isProduction = process.env.NODE_ENV !== 'development';
export function initHistoryWithGA() {
const history = createBrowserHistory();
export function wrapHistoryWithGA(history: History) {
if (isProduction) {
ReactGA.initialize('UA-28919359-15');
ReactGA.pageview(window.location.pathname + window.location.search);

View File

@@ -5,7 +5,7 @@ import XHR from 'i18next-xhr-backend';
import LanguageDetector from 'i18next-browser-languagedetector';
import {initReactI18next} from 'react-i18next';
const TRANSLATION_VERSION = '1.13';
const TRANSLATION_VERSION = '1.14';
i18n
.use(Backend)