1
0
mirror of https://github.com/ascribe/onion.git synced 2024-12-22 09:23:13 +01:00

Tighten lib-dependencies, move history into its own module

This commit is contained in:
Tim Daubenschütz 2015-10-05 11:52:23 +02:00
parent 31a83a1d61
commit c174b8b56c
4 changed files with 10 additions and 8 deletions

View File

@ -4,8 +4,7 @@ require('babel/polyfill');
import React from 'react';
import { Router, Redirect } from 'react-router';
import createBrowserHistory from 'history/lib/createBrowserHistory';
import history from './history';
/* eslint-disable */
import fetch from 'isomorphic-fetch';
@ -48,8 +47,6 @@ requests.defaults({
}
});
export let history = createBrowserHistory();
class AppGateway {
start() {
let settings;

5
js/history.js Normal file
View File

@ -0,0 +1,5 @@
'use strict';
import createBrowserHistory from 'history/lib/createBrowserHistory';
export default createBrowserHistory();

View File

@ -1,6 +1,6 @@
'use strict';
import { history } from '../app';
import history from '../history';
import alt from '../alt';
import EventActions from '../actions/event_actions';
@ -10,7 +10,6 @@ import { getSubdomain } from '../utils/general_utils';
class NotificationsHandler {
constructor() {
this.bindActions(EventActions);
this.loaded = false;
@ -20,6 +19,7 @@ class NotificationsHandler {
if (this.loaded) {
return;
}
let subdomain = getSubdomain();
if (subdomain === 'ikonotv') {
NotificationActions.fetchContractAgreementListNotifications().then(

View File

@ -73,8 +73,8 @@
"opn": "^3.0.2",
"q": "^1.4.1",
"raven-js": "^1.1.19",
"react": "^0.13.2",
"react-bootstrap": "^0.25.1",
"react": "0.13.2",
"react-bootstrap": "0.25.1",
"react-datepicker": "^0.12.0",
"react-router": "^1.0.0-rc1",
"react-router-bootstrap": "^0.19.0",