1
0
mirror of https://github.com/yldio/copilot.git synced 2024-11-28 14:10:04 +02:00

use existing aliases in the requires

This commit is contained in:
Sérgio Ramos 2016-12-05 20:28:10 +00:00
parent 23dab7b6cf
commit d63bea9571
9 changed files with 18 additions and 13 deletions

View File

@ -2,9 +2,11 @@ const React = require('react');
const ReactRedux = require('react-redux');
const ReactRouter = require('react-router');
const actions = require('../state/actions');
const Home = require('./home/');
const NotFound = require('./not-found/');
const actions = require('@state/actions');
const Home = require('@containers/home');
const NotFound = require('@containers/not-found');
const Header = require('@components/header');
const {
updateRouter

View File

@ -4,8 +4,8 @@ const ReactHotLoader = require('react-hot-loader');
const ReactRedux = require('react-redux');
const ReactRouter = require('react-router');
const App = require('./containers/app');
const store = require('./state/store');
const App = require('@containers/app');
const store = require('@state/store');
const {
IntlProvider

View File

@ -8,6 +8,6 @@ const {
const APP = constantCase(process.env['APP_NAME']);
module.exports = {
...require('./thunks'),
...require('@state/thunks'),
updateRouter: createAction(`${APP}/APP/UPDATE_ROUTER`)
};

View File

@ -1,5 +1,6 @@
const ReduxActions = require('redux-actions');
const actions = require('../actions');
const actions = require('@state/actions');
const {
handleActions

View File

@ -6,7 +6,7 @@ const {
module.exports = () => {
return combineReducers({
app: require('./app.js'),
intl: require('./intl.js')
app: require('@state/reducers/app'),
intl: require('@state/reducers/intl')
});
};

View File

@ -4,4 +4,6 @@ const {
handleActions
} = ReduxActions;
module.exports = handleActions({}, require('../../intl'));
module.exports = handleActions({
'x': (state) => state // somehow handleActions needs at least one reducer
}, require('@root/intl'));

View File

@ -1,10 +1,11 @@
const createLogger = require('redux-logger');
const createReducer = require('./reducers');
const enableBatching = require('redux-batched-actions').enableBatching;
const promiseMiddleware = require('redux-promise-middleware').default;
const redux = require('redux');
const thunk = require('redux-thunk').default;
const createReducer = require('@state/reducers');
const {
createStore,
compose,

View File

@ -1,3 +1,3 @@
module.exports = {
...require('./app')
...require('@state/thunks/app')
};

View File

@ -8,7 +8,6 @@ const Icon = ({
iconSet = 'fa',
style
}) => {
const Component = require(`react-icons/lib/${iconSet}/${name}`);
const cn = classNames(