diff --git a/.babelrc b/.babelrc
index 95b8ce0..9dce8c8 100644
--- a/.babelrc
+++ b/.babelrc
@@ -1,3 +1,4 @@
{
- "presets": ["stage-2", "es2015", "react"]
+ "plugins": ["universal-import"],
+ "presets": ["stage-2", "es2017", "react"]
}
\ No newline at end of file
diff --git a/.eslintrc b/.eslintrc
index a278674..3291474 100644
--- a/.eslintrc
+++ b/.eslintrc
@@ -11,9 +11,9 @@
"**/__tests__/**",
"**/__mocks__/**",
"**/*.{test,spec}.{js,jsx}",
- "**/stories/**"
+ "**/stories/**",
"**/__stories__/**",
- "**/*.story.{js,jsx}",
+ "**/*.story.{js,jsx}"
],
"optionalDependencies": false
}],
diff --git a/config/storybook/addons.js b/config/storybook/addons.js
index 6aed412..80d8ad3 100644
--- a/config/storybook/addons.js
+++ b/config/storybook/addons.js
@@ -1,2 +1,3 @@
+/* eslint-disable import/no-extraneous-dependencies */
import '@storybook/addon-actions/register';
import '@storybook/addon-links/register';
diff --git a/config/storybook/config.js b/config/storybook/config.js
index 2edb8fc..a0c4031 100644
--- a/config/storybook/config.js
+++ b/config/storybook/config.js
@@ -4,7 +4,7 @@ import { configure, addDecorator, setAddon } from '@storybook/react';
import { setOptions } from '@storybook/addon-options';
import { withKnobs } from '@storybook/addon-knobs/react';
import JSXAddon from 'storybook-addon-jsx';
-import styles from "@sambego/storybook-styles";
+import styles from '@sambego/storybook-styles';
import Provider from './Provider';
import { MemoryRouter } from 'react-router';
@@ -12,14 +12,14 @@ import { MemoryRouter } from 'react-router';
import configureStore from '../src/bootstrap/configureStore';
addDecorator(story => );
-addDecorator(story => {story()})
+addDecorator(story => {story()});
addDecorator(styles({
boxSizing: 'border-box',
fontFamily: "'Helvetica Neue','Helvetica','Arial',sans-serif",
fontSize: '16px',
margin: 0,
-}))
-setAddon(JSXAddon)
+}));
+setAddon(JSXAddon);
const req = require.context('../src/components/', true, /story\.(jsx|js)$/);
function loadStories() {
diff --git a/package.json b/package.json
index 98eb582..ce5a54b 100644
--- a/package.json
+++ b/package.json
@@ -3,31 +3,22 @@
"license": "MIT",
"version": "0.1.0",
"private": true,
+ "scripts": {
+ "start": "node scripts/start.js",
+ "build": "node scripts/build.js",
+ "test": "node scripts/test.js --env=jsdom",
+ "lint": "eslint . --fix",
+ "storybook": "start-storybook -p 9009 -s public -c config/storybook",
+ "build-storybook": "build-storybook -s public"
+ },
"dependencies": {
- "autoprefixer": "7.1.6",
- "babel-core": "6.26.0",
- "babel-eslint": "7.2.3",
- "babel-jest": "20.0.3",
- "babel-loader": "7.1.2",
- "babel-preset-react-app": "^3.1.1",
- "babel-runtime": "6.26.0",
- "case-sensitive-paths-webpack-plugin": "2.1.1",
"chalk": "1.1.3",
"css-loader": "0.28.7",
- "dotenv": "4.0.0",
- "dotenv-expand": "4.2.0",
- "eslint": "4.10.0",
- "eslint-config-react-app": "^2.1.0",
- "eslint-loader": "1.9.0",
- "eslint-plugin-flowtype": "2.39.1",
- "eslint-plugin-import": "2.8.0",
- "eslint-plugin-jsx-a11y": "5.1.1",
- "eslint-plugin-react": "7.4.0",
"extract-text-webpack-plugin": "3.0.2",
"file-loader": "1.1.5",
"fs-extra": "3.0.1",
+ "history": "^4.7.2",
"html-webpack-plugin": "2.29.0",
- "jest": "20.0.4",
"object-assign": "4.1.1",
"postcss-flexbugs-fixes": "3.2.0",
"postcss-loader": "2.0.8",
@@ -39,11 +30,10 @@
"react-dom": "^16.3.2",
"react-helmet": "^5.2.0",
"react-redux": "^5.0.7",
- "react-router": "^4.2.0",
- "react-router-dom": "^4.2.2",
- "react-router-redux": "^4.0.8",
"react-snapshot": "^1.3.0",
+ "react-universal-component": "^2.9.0",
"redux": "^4.0.0",
+ "redux-first-router": "^0.0.16-next",
"redux-logger": "^3.0.6",
"redux-thunk": "^2.2.0",
"resolve": "1.6.0",
@@ -56,14 +46,6 @@
"webpack-manifest-plugin": "1.3.2",
"whatwg-fetch": "2.0.3"
},
- "scripts": {
- "start": "node scripts/start.js",
- "build": "node scripts/build.js",
- "test": "node scripts/test.js --env=jsdom",
- "lint": "eslint . --fix",
- "storybook": "start-storybook -p 9009 -s public -c config/storybook",
- "build-storybook": "build-storybook -s public"
- },
"devDependencies": {
"@sambego/storybook-styles": "^1.0.0",
"@storybook/addon-actions": "^3.4.3",
@@ -73,14 +55,32 @@
"@storybook/addon-storyshots": "^3.4.3",
"@storybook/addons": "^3.4.3",
"@storybook/react": "^3.4.3",
+ "autoprefixer": "7.1.6",
+ "babel-cli": "^6.26.0",
"babel-core": "^6.26.3",
- "babel-preset-es2015": "^6.24.1",
+ "babel-eslint": "7.2.3",
+ "babel-jest": "20.0.3",
+ "babel-loader": "7.1.2",
+ "babel-plugin-universal-import": "^3.0.0",
+ "babel-preset-es2017": "^6.24.1",
+ "babel-preset-react-app": "^3.1.1",
"babel-preset-stage-2": "^6.24.1",
"babel-runtime": "^6.26.0",
+ "case-sensitive-paths-webpack-plugin": "2.1.1",
+ "dotenv": "4.0.0",
+ "dotenv-expand": "4.2.0",
"enzyme": "^3.3.0",
"enzyme-adapter-react-16": "^1.1.1",
"enzyme-to-json": "^3.3.3",
+ "eslint": "4.10.0",
"eslint-config-airbnb": "^16.1.0",
+ "eslint-config-react-app": "^2.1.0",
+ "eslint-loader": "1.9.0",
+ "eslint-plugin-flowtype": "2.39.1",
+ "eslint-plugin-import": "2.8.0",
+ "eslint-plugin-jsx-a11y": "^6.0.3",
+ "eslint-plugin-react": "7.4.0",
+ "jest": "20.0.4",
"jest-styled-components": "^5.0.1",
"storybook-addon-jsx": "^5.3.0"
},
diff --git a/src/actions/index.js b/src/actions/index.js
new file mode 100644
index 0000000..83f91c9
--- /dev/null
+++ b/src/actions/index.js
@@ -0,0 +1,4 @@
+import exportAllDefaults from '../utils/exportAllDefaults';
+
+const context = require.context('.', false, /\.js/);
+export default exportAllDefaults(context);
diff --git a/src/actions/plants.js b/src/actions/plants.js
new file mode 100644
index 0000000..3680a95
--- /dev/null
+++ b/src/actions/plants.js
@@ -0,0 +1,12 @@
+// ADD_PLANT, UPDATE_PLANT, DELETE_PLANT, GET_PLANT,
+import { LIST_PLANTS, SET_PLANTS } from '../constants/actionTypes';
+import * as api from '../constants/apiTypes';
+import makeActionCreator from '../utils/makeActionCreator';
+import apiActionCreator from '../utils/apiActionCreator';
+
+// export const createPlant = makeActionCreator(ADD_PLANT, 'plant');
+// export const updatePlant = makeActionCreator(UPDATE_PLANT, 'id', 'plant');
+// export const getPlant = makeActionCreator(GET_PLANT, 'id');
+// export const deletePlant = makeActionCreator(DELETE_PLANT, 'id');
+export const listPlants = apiActionCreator(LIST_PLANTS, api.GET_PLANTS, 'gardenId');
+export const setPlants = makeActionCreator(SET_PLANTS, 'gardenId', 'plants');
diff --git a/src/constants/actionTypes.js b/src/constants/actionTypes.js
new file mode 100644
index 0000000..760e455
--- /dev/null
+++ b/src/constants/actionTypes.js
@@ -0,0 +1,10 @@
+export const API_LOADING = 'API_LOADING';
+export const API_SUCCESS = 'API_SUCCESS';
+export const API_ERROR = 'API_ERROR';
+
+export const ADD_PLANT = 'ADD_PLANT';
+export const UPDATE_PLANT = 'UPDATE_PLANT';
+export const DELETE_PLANT = 'DELETE_PLANT';
+export const GET_PLANT = 'GET_PLANT';
+export const LIST_PLANTS = 'LIST_PLANTS';
+export const SET_PLANTS = 'SET_PLANTS';
diff --git a/src/constants/apiTypes.js b/src/constants/apiTypes.js
new file mode 100644
index 0000000..ca7de24
--- /dev/null
+++ b/src/constants/apiTypes.js
@@ -0,0 +1,2 @@
+export const GET_PLANTS = 'getPlants';
+export const GET_GARDENS = 'getGardens';
diff --git a/src/constants/pageNames.js b/src/constants/pageNames.js
new file mode 100644
index 0000000..6121c94
--- /dev/null
+++ b/src/constants/pageNames.js
@@ -0,0 +1,12 @@
+const context = require.context('../containers/pages', false, /\.jsx/);
+const pageNames = {};
+context.keys().forEach((key) => {
+ if (key !== '.' && key !== '..') {
+ const name = key.replace(/\.\//, '').split('.')[0];
+ if (name !== 'index') {
+ pageNames[name] = name;
+ }
+ }
+});
+
+export default pageNames;
diff --git a/src/containers/layout/App.jsx b/src/containers/layout/App.jsx
index 16cb192..0b0ed21 100644
--- a/src/containers/layout/App.jsx
+++ b/src/containers/layout/App.jsx
@@ -1,14 +1,24 @@
-import React, { Fragment } from 'react';
-import Router from '../../init/router';
-
-const App = () => (
-
-
-
-
-
-
-
-);
-
-export default App;
+import React, { Fragment } from 'react';
+import { connect } from 'react-redux';
+import PropTypes from 'prop-types';
+import universal from 'react-universal-component';
+
+const UniversalComponent = universal(({ page }) => import(`../pages/${page}`));
+
+const App = ({ page }) => (
+
+
+
+
+
+
+
+);
+
+const mapStateToProps = ({ page }) => ({ page });
+
+export default connect(mapStateToProps)(App);
+
+App.propTypes = {
+ page: PropTypes.string.isRequired,
+};
diff --git a/src/containers/pages/GardenPage.jsx b/src/containers/pages/GardenPage.jsx
new file mode 100644
index 0000000..923b36f
--- /dev/null
+++ b/src/containers/pages/GardenPage.jsx
@@ -0,0 +1,27 @@
+
+import React from 'react';
+import { connect } from 'react-redux';
+import PropTypes from 'prop-types';
+
+const GardenPage = props => (
+
+ {props.plants.map(garden =>
{ garden.name }
)}
+
+);
+
+const mapStateToProps = state => ({
+ plants: state.plants,
+});
+export default connect(mapStateToProps)(GardenPage);
+
+GardenPage.propTypes = {
+ plants: PropTypes.arrayOf(PropTypes.shape({
+ id: PropTypes.int,
+ name: PropTypes.string,
+ daysTillHarvest: PropTypes.int,
+ })),
+};
+
+GardenPage.defaultProps = {
+ plants: [],
+};
diff --git a/src/containers/pages/HomePage.jsx b/src/containers/pages/HomePage.jsx
new file mode 100644
index 0000000..9bb8446
--- /dev/null
+++ b/src/containers/pages/HomePage.jsx
@@ -0,0 +1,10 @@
+
+import React from 'react';
+
+const NotFoundPage = () => (
+
+ Home Page
+
+);
+
+export default NotFoundPage;
diff --git a/src/containers/pages/NotFoundPage.jsx b/src/containers/pages/NotFoundPage.jsx
new file mode 100644
index 0000000..a8828a9
--- /dev/null
+++ b/src/containers/pages/NotFoundPage.jsx
@@ -0,0 +1,10 @@
+
+import React from 'react';
+
+const NotFoundPage = () => (
+
+ Page Not Found
+
+);
+
+export default NotFoundPage;
diff --git a/src/containers/pages/index.js b/src/containers/pages/index.js
new file mode 100644
index 0000000..66dca00
--- /dev/null
+++ b/src/containers/pages/index.js
@@ -0,0 +1,4 @@
+import exportAllDefaults from '../../utils/exportAllDefaults';
+
+const context = require.context('.', false, /\.jsx/);
+export default exportAllDefaults(context);
diff --git a/src/init/api.js b/src/init/api.js
new file mode 100644
index 0000000..566f9d3
--- /dev/null
+++ b/src/init/api.js
@@ -0,0 +1,33 @@
+import * as api from '../constants/apiTypes';
+
+function Api(name, ...params) {
+ return typeof Api[name] === 'function' ? Api[name](...params) : null;
+}
+
+Api[api.GET_PLANTS] = (gardenId) => {
+ const response = {
+ success: true,
+ data: {
+ gardenId,
+ plants: [
+ { id: 1, name: 'strawberry', daysTillHarvest: 80 },
+ ],
+ },
+ };
+
+ // fetch(...)
+ // for now simulating delay with a promise that takes time to resolve
+ return new Promise(resolve => setTimeout(resolve, 1000)).then(() => {
+ if (response.success !== true || typeof response.data === 'undefined') {
+ if (response.error) {
+ throw Error(response.error);
+ } else {
+ throw Error('Invalid Response');
+ }
+ }
+
+ return response.data;
+ });
+};
+
+export default Api;
diff --git a/src/init/dev.js b/src/init/dev.js
index 9e28684..ac2257d 100644
--- a/src/init/dev.js
+++ b/src/init/dev.js
@@ -1,4 +1,5 @@
-// logging
-import { createLogger } from 'redux-logger';
-
-exports.initDev = (middleware) => middleware.push(createLogger());
+// logging
+import { createLogger } from 'redux-logger';
+
+const initDev = middleware => middleware.push(createLogger());
+export default initDev;
diff --git a/src/init/index.jsx b/src/init/index.jsx
index 0af068a..8ae097d 100644
--- a/src/init/index.jsx
+++ b/src/init/index.jsx
@@ -1,43 +1,32 @@
-import React from 'react';
-import { render } from 'react-snapshot';
-
-// redux / state
-import { Provider } from 'react-redux';
-import thunk from 'redux-thunk';
-
-// routing
-import createHistory from 'history/createBrowserHistory';
-import { BrowserRouter } from 'react-router-dom';
-import { routerMiddleware } from 'react-router-redux';
-
-// app
-import initStore from './store';
-import App from '../containers/layout/App';
-import styleInit from './styledComponents';
-
-// api (todo make it an import)
-const Api = {};
-
-// middleware
-const history = createHistory();
-const middleware = [routerMiddleware(history), thunk.withExtraArgument(Api)];
-if (process.env.NODE_ENV !== 'production') {
- const initDev = require('./dev.js');
- initDev(middleware);
-}
-
-const store = initStore(middleware);
-
-styleInit();
-
-// todo consider using ConnectedRouter
-export default function init() {
- render(
-
-
-
-
- ,
- document.getElementById('root'),
- );
-}
+import React from 'react';
+import { render } from 'react-snapshot';
+
+// redux / state
+import { Provider } from 'react-redux';
+import thunk from 'redux-thunk';
+
+// app
+import initStore from './store';
+import App from '../containers/layout/App';
+import styleInit from './styledcomponents';
+import Api from './api';
+
+// middleware
+const middleware = [thunk.withExtraArgument(Api)];
+if (process.env.NODE_ENV !== 'production') {
+ import('./dev.js').then(initDev => initDev.default(middleware));
+}
+
+const { store } = initStore({});
+
+styleInit();
+
+export default () => {
+ render(
+
+
+
+ ,
+ document.getElementById('root'),
+ );
+};
diff --git a/src/init/router.js b/src/init/router.js
new file mode 100644
index 0000000..6cc813a
--- /dev/null
+++ b/src/init/router.js
@@ -0,0 +1,13 @@
+import { connectRoutes } from 'redux-first-router';
+import createHistory from 'history/createBrowserHistory';
+
+import routes from './routes';
+
+const history = createHistory();
+const options = {};
+
+export default connectRoutes(
+ history,
+ routes,
+ options,
+);
diff --git a/src/init/router.jsx b/src/init/router.jsx
deleted file mode 100644
index 7ef010c..0000000
--- a/src/init/router.jsx
+++ /dev/null
@@ -1,12 +0,0 @@
-import React from 'react';
-import { Switch, Route } from 'react-router-dom';
-
-const PlaceholderPage = (Placeholder
);
-
-const Router = () => (
-
-
-
-);
-
-export default Router;
diff --git a/src/init/routes.js b/src/init/routes.js
new file mode 100644
index 0000000..2b9000b
--- /dev/null
+++ b/src/init/routes.js
@@ -0,0 +1,24 @@
+import { NOT_FOUND } from 'redux-first-router';
+import * as plantActionCreators from '../actions/plants';
+import * as api from '../constants/apiTypes';
+import Api from './api';
+
+export default {
+ HomePage: '/',
+ GardenPage: {
+ path: '/garden/:id',
+ thunk: async (dispatch, getState) => {
+ const { location: { payload: { id } } } = getState();
+
+ try {
+ const response = await Api(api.GET_PLANTS);
+
+ dispatch(plantActionCreators.setPlants(id, response.plants)(dispatch));
+ } catch (error) {
+ // eslint-disable-next-line
+ console.log(error);
+ dispatch({ type: NOT_FOUND });
+ }
+ },
+ },
+};
diff --git a/src/init/store.js b/src/init/store.js
index 304f9ca..ec02188 100644
--- a/src/init/store.js
+++ b/src/init/store.js
@@ -1,13 +1,19 @@
-import { createStore, combineReducers, applyMiddleware } from 'redux';
-import { routerReducer } from 'react-router-redux';
-
-const combinedReducers = combineReducers({
- router: routerReducer,
-});
-
-const initState = {};
-
-const configureStore = (middleware = []) =>
- createStore(combinedReducers, initState, applyMiddleware(...middleware));
-
-export default configureStore;
+import { createStore, applyMiddleware, compose, combineReducers } from 'redux';
+import createRouter from './router';
+import reducers from '../reducers';
+
+export default (preLoadedState) => {
+ const {
+ reducer, middleware, enhancer, thunk,
+ } = createRouter;
+
+ const composeEnhancers = (...args) => compose(...args);
+
+ const rootReducer = combineReducers({ ...reducers, location: reducer });
+ // todo apply middleware from index.jsx page
+ const middlewares = applyMiddleware(middleware);
+ const enhancers = composeEnhancers(enhancer, middlewares);
+ const store = createStore(rootReducer, preLoadedState, enhancers);
+
+ return { store, thunk };
+};
diff --git a/src/init/styledcomponents.js b/src/init/styledcomponents.js
index dde5761..3a79089 100644
--- a/src/init/styledcomponents.js
+++ b/src/init/styledcomponents.js
@@ -1,67 +1,67 @@
-// these sizes are arbitrary and you can set them to whatever you wish
-import { css, injectGlobal } from 'styled-components';
-
-// global styles
-export default () => injectGlobal(`
- body {
- box-sizing: border-box;
- font-family: 'Helvetica Neue','Helvetica','Arial',sans-serif;
- font-size: 16px;
- margin: 0;
- padding: 0
- }
-`);
-
-// Helpers for accessability purposes
-export const a11y = {
- srOnly: () => css`
- position: absolute;
- width: 1px;
- height: 1px;
- padding: 0;
- overflow: hidden;
- clip: rect(0, 0, 0, 0);
- white-space: nowrap;
- clip-path: inset(50%);
- border: 0;
- `,
- srOnlyFocus: () => css`
- &:active, &:focus {
- position: static;
- width: auto;
- height: auto;
- overflow: visible;
- clip: auto;
- white-space: normal;
- clip-path: none;
- }
- `,
- focus: () => css`
- &:active, &:focus {
- outline: 1px dashed #333;
- outline-offset: 2px;
- text-decoration: underline;
- }
- `,
-};
-
-// media queries
-const sizes = {
- mobile: 1000,
-};
-
-// iterate through the sizes and create a media template
-export const media = Object.keys(sizes).reduce((accumulator, label) => {
- // use em in breakpoints to work properly cross-browser and support users
- // changing their browsers font-size: https://zellwk.com/blog/media-query-units/
- const emSize = sizes[label] / 16;
- return {
- ...accumulator,
- [label]: (...args) => css`
- @media (max-width: ${emSize}em) {
- ${css(...args)}
- }
- `,
- };
-}, {});
-
+// these sizes are arbitrary and you can set them to whatever you wish
+import { css, injectGlobal } from 'styled-components';
+
+// global styles
+export default () => injectGlobal(`
+ body {
+ box-sizing: border-box;
+ font-family: 'Helvetica Neue','Helvetica','Arial',sans-serif;
+ font-size: 16px;
+ margin: 0;
+ padding: 0
+ }
+`);
+
+// Helpers for accessability purposes
+export const a11y = {
+ srOnly: () => css`
+ position: absolute;
+ width: 1px;
+ height: 1px;
+ padding: 0;
+ overflow: hidden;
+ clip: rect(0, 0, 0, 0);
+ white-space: nowrap;
+ clip-path: inset(50%);
+ border: 0;
+ `,
+ srOnlyFocus: () => css`
+ &:active, &:focus {
+ position: static;
+ width: auto;
+ height: auto;
+ overflow: visible;
+ clip: auto;
+ white-space: normal;
+ clip-path: none;
+ }
+ `,
+ focus: () => css`
+ &:active, &:focus {
+ outline: 1px dashed #333;
+ outline-offset: 2px;
+ text-decoration: underline;
+ }
+ `,
+};
+
+// media queries
+const sizes = {
+ mobile: 1000,
+};
+
+// iterate through the sizes and create a media template
+export const media = Object.keys(sizes).reduce((accumulator, label) => {
+ // use em in breakpoints to work properly cross-browser and support users
+ // changing their browsers font-size: https://zellwk.com/blog/media-query-units/
+ const emSize = sizes[label] / 16;
+ return {
+ ...accumulator,
+ [label]: (...args) => css`
+ @media (max-width: ${emSize}em) {
+ ${css(...args)}
+ }
+ `,
+ };
+}, {});
+
diff --git a/src/reducers/index.js b/src/reducers/index.js
new file mode 100644
index 0000000..83f91c9
--- /dev/null
+++ b/src/reducers/index.js
@@ -0,0 +1,4 @@
+import exportAllDefaults from '../utils/exportAllDefaults';
+
+const context = require.context('.', false, /\.js/);
+export default exportAllDefaults(context);
diff --git a/src/reducers/page.js b/src/reducers/page.js
new file mode 100644
index 0000000..5c515a2
--- /dev/null
+++ b/src/reducers/page.js
@@ -0,0 +1,10 @@
+import { NOT_FOUND } from 'redux-first-router';
+import pages from '../constants/pageNames';
+
+const components = {
+ ...pages,
+ [NOT_FOUND]: 'NotFoundPage',
+};
+
+export default (state = 'HomePage', action = {}) => components[action.type] || state;
+
diff --git a/src/reducers/plants.js b/src/reducers/plants.js
new file mode 100644
index 0000000..5ca0b89
--- /dev/null
+++ b/src/reducers/plants.js
@@ -0,0 +1,4 @@
+import { SET_PLANTS } from '../constants/actionTypes';
+
+export default (state = [], action = {}) => (action.type === SET_PLANTS ? action.plants : state);
+
diff --git a/src/utils/apiActionCreator.js b/src/utils/apiActionCreator.js
new file mode 100644
index 0000000..5f816b1
--- /dev/null
+++ b/src/utils/apiActionCreator.js
@@ -0,0 +1,38 @@
+import { API_LOADING, API_SUCCESS, API_ERROR } from '../constants/actionTypes';
+import Api from '../init/api';
+
+export default function apiActionCreator(type, request, argNames, options) {
+ return function action(...args) {
+ return function thunk(dispatch) {
+ const types = {
+ API_LOADING,
+ API_SUCCESS,
+ API_ERROR,
+ ...options,
+ };
+
+ const apiArgs = {};
+ argNames.forEach((arg, index) => {
+ apiArgs[argNames[index]] = args[index];
+ });
+
+ dispatch({ type: types[API_LOADING] });
+ Api[request](...apiArgs).then(
+ response =>
+ dispatch({
+ type: types[API_SUCCESS],
+ request,
+ args,
+ response,
+ }),
+ error =>
+ dispatch({
+ type: types[API_ERROR],
+ request,
+ args,
+ error,
+ }),
+ );
+ };
+ };
+}
diff --git a/src/utils/exportAllDefaults.js b/src/utils/exportAllDefaults.js
new file mode 100644
index 0000000..4905408
--- /dev/null
+++ b/src/utils/exportAllDefaults.js
@@ -0,0 +1,14 @@
+
+export default (context) => {
+ const obj = {};
+ context.keys().forEach((key) => {
+ if (key !== '.' && key !== '..') {
+ const name = key.replace(/\.\//, '').split('.')[0];
+ if (name !== 'index') {
+ obj[name] = context(key).default;
+ }
+ }
+ });
+
+ return obj;
+};
diff --git a/src/utils/makeActionCreator.js b/src/utils/makeActionCreator.js
new file mode 100644
index 0000000..d547142
--- /dev/null
+++ b/src/utils/makeActionCreator.js
@@ -0,0 +1,9 @@
+export default function makeActionCreator(type, ...argNames) {
+ return (...args) => () => {
+ const action = { type };
+ argNames.forEach((arg, index) => {
+ action[argNames[index]] = args[index];
+ });
+ return action;
+ };
+}
diff --git a/yarn.lock b/yarn.lock
index 884df9a..310ec9a 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -2,6 +2,21 @@
# yarn lockfile v1
+"@babel/helper-module-imports@^7.0.0-beta.49":
+ version "7.0.0-beta.49"
+ resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.0.0-beta.49.tgz#41d7d59891016c493432a46f7464446552890c75"
+ dependencies:
+ "@babel/types" "7.0.0-beta.49"
+ lodash "^4.17.5"
+
+"@babel/types@7.0.0-beta.49":
+ version "7.0.0-beta.49"
+ resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.0.0-beta.49.tgz#b7e3b1c3f4d4cfe11bdf8c89f1efd5e1617b87a6"
+ dependencies:
+ esutils "^2.0.2"
+ lodash "^4.17.5"
+ to-fast-properties "^2.0.0"
+
"@sambego/storybook-styles@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@sambego/storybook-styles/-/storybook-styles-1.0.0.tgz#4f840ee26dd0b25dcb803a75caa42e16071dcaae"
@@ -651,39 +666,36 @@ axobject-query@^0.1.0:
dependencies:
ast-types-flow "0.0.7"
-babel-code-frame@6.26.0, babel-code-frame@^6.11.0, babel-code-frame@^6.22.0, babel-code-frame@^6.26.0:
- version "6.26.0"
- resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b"
- dependencies:
- chalk "^1.1.3"
- esutils "^2.0.2"
- js-tokens "^3.0.2"
-
-babel-core@6.26.0:
+babel-cli@^6.26.0:
version "6.26.0"
- resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.0.tgz#af32f78b31a6fcef119c87b0fd8d9753f03a0bb8"
+ resolved "https://registry.yarnpkg.com/babel-cli/-/babel-cli-6.26.0.tgz#502ab54874d7db88ad00b887a06383ce03d002f1"
dependencies:
- babel-code-frame "^6.26.0"
- babel-generator "^6.26.0"
- babel-helpers "^6.24.1"
- babel-messages "^6.23.0"
+ babel-core "^6.26.0"
+ babel-polyfill "^6.26.0"
babel-register "^6.26.0"
babel-runtime "^6.26.0"
- babel-template "^6.26.0"
- babel-traverse "^6.26.0"
- babel-types "^6.26.0"
- babylon "^6.18.0"
+ commander "^2.11.0"
convert-source-map "^1.5.0"
- debug "^2.6.8"
- json5 "^0.5.1"
+ fs-readdir-recursive "^1.0.0"
+ glob "^7.1.2"
lodash "^4.17.4"
- minimatch "^3.0.4"
+ output-file-sync "^1.1.2"
path-is-absolute "^1.0.1"
- private "^0.1.7"
slash "^1.0.0"
source-map "^0.5.6"
+ v8flags "^2.1.1"
+ optionalDependencies:
+ chokidar "^1.6.1"
+
+babel-code-frame@6.26.0, babel-code-frame@^6.11.0, babel-code-frame@^6.22.0, babel-code-frame@^6.26.0:
+ version "6.26.0"
+ resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b"
+ dependencies:
+ chalk "^1.1.3"
+ esutils "^2.0.2"
+ js-tokens "^3.0.2"
-babel-core@^6.0.0, babel-core@^6.26.0:
+babel-core@^6.0.0, babel-core@^6.26.0, babel-core@^6.26.3:
version "6.26.3"
resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.3.tgz#b2e2f09e342d0f0c88e2f02e067794125e75c207"
dependencies:
@@ -1137,7 +1149,7 @@ babel-plugin-transform-es2015-block-scoped-functions@^6.22.0:
dependencies:
babel-runtime "^6.22.0"
-babel-plugin-transform-es2015-block-scoping@^6.23.0, babel-plugin-transform-es2015-block-scoping@^6.24.1:
+babel-plugin-transform-es2015-block-scoping@^6.23.0:
version "6.26.0"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-block-scoping/-/babel-plugin-transform-es2015-block-scoping-6.26.0.tgz#d70f5299c1308d05c12f463813b0a09e73b1895f"
dependencies:
@@ -1147,7 +1159,7 @@ babel-plugin-transform-es2015-block-scoping@^6.23.0, babel-plugin-transform-es20
babel-types "^6.26.0"
lodash "^4.17.4"
-babel-plugin-transform-es2015-classes@^6.23.0, babel-plugin-transform-es2015-classes@^6.24.1:
+babel-plugin-transform-es2015-classes@^6.23.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-classes/-/babel-plugin-transform-es2015-classes-6.24.1.tgz#5a4c58a50c9c9461e564b4b2a3bfabc97a2584db"
dependencies:
@@ -1161,33 +1173,33 @@ babel-plugin-transform-es2015-classes@^6.23.0, babel-plugin-transform-es2015-cla
babel-traverse "^6.24.1"
babel-types "^6.24.1"
-babel-plugin-transform-es2015-computed-properties@^6.22.0, babel-plugin-transform-es2015-computed-properties@^6.24.1:
+babel-plugin-transform-es2015-computed-properties@^6.22.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-computed-properties/-/babel-plugin-transform-es2015-computed-properties-6.24.1.tgz#6fe2a8d16895d5634f4cd999b6d3480a308159b3"
dependencies:
babel-runtime "^6.22.0"
babel-template "^6.24.1"
-babel-plugin-transform-es2015-destructuring@6.23.0, babel-plugin-transform-es2015-destructuring@^6.22.0, babel-plugin-transform-es2015-destructuring@^6.23.0:
+babel-plugin-transform-es2015-destructuring@6.23.0, babel-plugin-transform-es2015-destructuring@^6.23.0:
version "6.23.0"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz#997bb1f1ab967f682d2b0876fe358d60e765c56d"
dependencies:
babel-runtime "^6.22.0"
-babel-plugin-transform-es2015-duplicate-keys@^6.22.0, babel-plugin-transform-es2015-duplicate-keys@^6.24.1:
+babel-plugin-transform-es2015-duplicate-keys@^6.22.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-duplicate-keys/-/babel-plugin-transform-es2015-duplicate-keys-6.24.1.tgz#73eb3d310ca969e3ef9ec91c53741a6f1576423e"
dependencies:
babel-runtime "^6.22.0"
babel-types "^6.24.1"
-babel-plugin-transform-es2015-for-of@^6.22.0, babel-plugin-transform-es2015-for-of@^6.23.0:
+babel-plugin-transform-es2015-for-of@^6.23.0:
version "6.23.0"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-for-of/-/babel-plugin-transform-es2015-for-of-6.23.0.tgz#f47c95b2b613df1d3ecc2fdb7573623c75248691"
dependencies:
babel-runtime "^6.22.0"
-babel-plugin-transform-es2015-function-name@^6.22.0, babel-plugin-transform-es2015-function-name@^6.24.1:
+babel-plugin-transform-es2015-function-name@^6.22.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-function-name/-/babel-plugin-transform-es2015-function-name-6.24.1.tgz#834c89853bc36b1af0f3a4c5dbaa94fd8eacaa8b"
dependencies:
@@ -1218,7 +1230,7 @@ babel-plugin-transform-es2015-modules-commonjs@^6.23.0, babel-plugin-transform-e
babel-template "^6.26.0"
babel-types "^6.26.0"
-babel-plugin-transform-es2015-modules-systemjs@^6.23.0, babel-plugin-transform-es2015-modules-systemjs@^6.24.1:
+babel-plugin-transform-es2015-modules-systemjs@^6.23.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-systemjs/-/babel-plugin-transform-es2015-modules-systemjs-6.24.1.tgz#ff89a142b9119a906195f5f106ecf305d9407d23"
dependencies:
@@ -1226,7 +1238,7 @@ babel-plugin-transform-es2015-modules-systemjs@^6.23.0, babel-plugin-transform-e
babel-runtime "^6.22.0"
babel-template "^6.24.1"
-babel-plugin-transform-es2015-modules-umd@^6.23.0, babel-plugin-transform-es2015-modules-umd@^6.24.1:
+babel-plugin-transform-es2015-modules-umd@^6.23.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-umd/-/babel-plugin-transform-es2015-modules-umd-6.24.1.tgz#ac997e6285cd18ed6176adb607d602344ad38468"
dependencies:
@@ -1234,14 +1246,14 @@ babel-plugin-transform-es2015-modules-umd@^6.23.0, babel-plugin-transform-es2015
babel-runtime "^6.22.0"
babel-template "^6.24.1"
-babel-plugin-transform-es2015-object-super@^6.22.0, babel-plugin-transform-es2015-object-super@^6.24.1:
+babel-plugin-transform-es2015-object-super@^6.22.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-object-super/-/babel-plugin-transform-es2015-object-super-6.24.1.tgz#24cef69ae21cb83a7f8603dad021f572eb278f8d"
dependencies:
babel-helper-replace-supers "^6.24.1"
babel-runtime "^6.22.0"
-babel-plugin-transform-es2015-parameters@^6.23.0, babel-plugin-transform-es2015-parameters@^6.24.1:
+babel-plugin-transform-es2015-parameters@^6.23.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-parameters/-/babel-plugin-transform-es2015-parameters-6.24.1.tgz#57ac351ab49caf14a97cd13b09f66fdf0a625f2b"
dependencies:
@@ -1252,7 +1264,7 @@ babel-plugin-transform-es2015-parameters@^6.23.0, babel-plugin-transform-es2015-
babel-traverse "^6.24.1"
babel-types "^6.24.1"
-babel-plugin-transform-es2015-shorthand-properties@^6.22.0, babel-plugin-transform-es2015-shorthand-properties@^6.24.1:
+babel-plugin-transform-es2015-shorthand-properties@^6.22.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-shorthand-properties/-/babel-plugin-transform-es2015-shorthand-properties-6.24.1.tgz#24f875d6721c87661bbd99a4622e51f14de38aa0"
dependencies:
@@ -1265,7 +1277,7 @@ babel-plugin-transform-es2015-spread@^6.22.0:
dependencies:
babel-runtime "^6.22.0"
-babel-plugin-transform-es2015-sticky-regex@^6.22.0, babel-plugin-transform-es2015-sticky-regex@^6.24.1:
+babel-plugin-transform-es2015-sticky-regex@^6.22.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-sticky-regex/-/babel-plugin-transform-es2015-sticky-regex-6.24.1.tgz#00c1cdb1aca71112cdf0cf6126c2ed6b457ccdbc"
dependencies:
@@ -1279,13 +1291,13 @@ babel-plugin-transform-es2015-template-literals@^6.22.0:
dependencies:
babel-runtime "^6.22.0"
-babel-plugin-transform-es2015-typeof-symbol@^6.22.0, babel-plugin-transform-es2015-typeof-symbol@^6.23.0:
+babel-plugin-transform-es2015-typeof-symbol@^6.23.0:
version "6.23.0"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-typeof-symbol/-/babel-plugin-transform-es2015-typeof-symbol-6.23.0.tgz#dec09f1cddff94b52ac73d505c84df59dcceb372"
dependencies:
babel-runtime "^6.22.0"
-babel-plugin-transform-es2015-unicode-regex@^6.22.0, babel-plugin-transform-es2015-unicode-regex@^6.24.1:
+babel-plugin-transform-es2015-unicode-regex@^6.22.0:
version "6.24.1"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-unicode-regex/-/babel-plugin-transform-es2015-unicode-regex-6.24.1.tgz#d38b12f42ea7323f729387f18a7c5ae1faeb35e9"
dependencies:
@@ -1385,7 +1397,7 @@ babel-plugin-transform-react-jsx@6.24.1, babel-plugin-transform-react-jsx@^6.24.
babel-plugin-syntax-jsx "^6.8.0"
babel-runtime "^6.22.0"
-babel-plugin-transform-regenerator@6.26.0, babel-plugin-transform-regenerator@^6.22.0, babel-plugin-transform-regenerator@^6.24.1, babel-plugin-transform-regenerator@^6.26.0:
+babel-plugin-transform-regenerator@6.26.0, babel-plugin-transform-regenerator@^6.22.0, babel-plugin-transform-regenerator@^6.26.0:
version "6.26.0"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-regenerator/-/babel-plugin-transform-regenerator-6.26.0.tgz#e0703696fbde27f0a3efcacf8b4dca2f7b3a8f2f"
dependencies:
@@ -1430,6 +1442,20 @@ babel-plugin-transform-undefined-to-void@^6.9.0:
version "6.9.2"
resolved "https://registry.yarnpkg.com/babel-plugin-transform-undefined-to-void/-/babel-plugin-transform-undefined-to-void-6.9.2.tgz#165fde73393276bea02a739658878dcced0b9ebb"
+babel-plugin-universal-import@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/babel-plugin-universal-import/-/babel-plugin-universal-import-3.0.0.tgz#0f72bd9b3195a818777bd85ab103cc1bc7418ba8"
+ dependencies:
+ "@babel/helper-module-imports" "^7.0.0-beta.49"
+
+babel-polyfill@^6.26.0:
+ version "6.26.0"
+ resolved "https://registry.yarnpkg.com/babel-polyfill/-/babel-polyfill-6.26.0.tgz#379937abc67d7895970adc621f284cd966cf2153"
+ dependencies:
+ babel-runtime "^6.26.0"
+ core-js "^2.5.0"
+ regenerator-runtime "^0.10.5"
+
babel-preset-env@1.6.1:
version "1.6.1"
resolved "https://registry.yarnpkg.com/babel-preset-env/-/babel-preset-env-1.6.1.tgz#a18b564cc9b9afdf4aae57ae3c1b0d99188e6f48"
@@ -1500,34 +1526,12 @@ babel-preset-env@^1.6.1:
invariant "^2.2.2"
semver "^5.3.0"
-babel-preset-es2015@^6.24.1:
+babel-preset-es2017@^6.24.1:
version "6.24.1"
- resolved "https://registry.yarnpkg.com/babel-preset-es2015/-/babel-preset-es2015-6.24.1.tgz#d44050d6bc2c9feea702aaf38d727a0210538939"
+ resolved "https://registry.yarnpkg.com/babel-preset-es2017/-/babel-preset-es2017-6.24.1.tgz#597beadfb9f7f208bcfd8a12e9b2b29b8b2f14d1"
dependencies:
- babel-plugin-check-es2015-constants "^6.22.0"
- babel-plugin-transform-es2015-arrow-functions "^6.22.0"
- babel-plugin-transform-es2015-block-scoped-functions "^6.22.0"
- babel-plugin-transform-es2015-block-scoping "^6.24.1"
- babel-plugin-transform-es2015-classes "^6.24.1"
- babel-plugin-transform-es2015-computed-properties "^6.24.1"
- babel-plugin-transform-es2015-destructuring "^6.22.0"
- babel-plugin-transform-es2015-duplicate-keys "^6.24.1"
- babel-plugin-transform-es2015-for-of "^6.22.0"
- babel-plugin-transform-es2015-function-name "^6.24.1"
- babel-plugin-transform-es2015-literals "^6.22.0"
- babel-plugin-transform-es2015-modules-amd "^6.24.1"
- babel-plugin-transform-es2015-modules-commonjs "^6.24.1"
- babel-plugin-transform-es2015-modules-systemjs "^6.24.1"
- babel-plugin-transform-es2015-modules-umd "^6.24.1"
- babel-plugin-transform-es2015-object-super "^6.24.1"
- babel-plugin-transform-es2015-parameters "^6.24.1"
- babel-plugin-transform-es2015-shorthand-properties "^6.24.1"
- babel-plugin-transform-es2015-spread "^6.22.0"
- babel-plugin-transform-es2015-sticky-regex "^6.24.1"
- babel-plugin-transform-es2015-template-literals "^6.22.0"
- babel-plugin-transform-es2015-typeof-symbol "^6.22.0"
- babel-plugin-transform-es2015-unicode-regex "^6.24.1"
- babel-plugin-transform-regenerator "^6.24.1"
+ babel-plugin-syntax-trailing-function-commas "^6.22.0"
+ babel-plugin-transform-async-to-generator "^6.24.1"
babel-preset-flow@^6.23.0:
version "6.23.0"
@@ -1645,7 +1649,7 @@ babel-register@^6.26.0:
mkdirp "^0.5.1"
source-map-support "^0.4.15"
-babel-runtime@6.26.0, babel-runtime@6.x.x, babel-runtime@^6.11.6, babel-runtime@^6.18.0, babel-runtime@^6.22.0, babel-runtime@^6.23.0, babel-runtime@^6.26.0, babel-runtime@^6.5.0, babel-runtime@^6.9.2:
+babel-runtime@6.x.x, babel-runtime@^6.11.6, babel-runtime@^6.18.0, babel-runtime@^6.22.0, babel-runtime@^6.23.0, babel-runtime@^6.26.0, babel-runtime@^6.5.0, babel-runtime@^6.9.2:
version "6.26.0"
resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe"
dependencies:
@@ -2118,7 +2122,7 @@ cheerio@^1.0.0-rc.2:
lodash "^4.15.0"
parse5 "^3.0.1"
-chokidar@^1.6.0:
+chokidar@^1.6.0, chokidar@^1.6.1:
version "1.7.0"
resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-1.7.0.tgz#798e689778151c8076b4b360e5edd28cda2bb468"
dependencies:
@@ -3175,7 +3179,7 @@ error-ex@^1.2.0, error-ex@^1.3.1:
dependencies:
is-arrayish "^0.2.1"
-es-abstract@^1.10.0, es-abstract@^1.4.3, es-abstract@^1.5.1, es-abstract@^1.6.1, es-abstract@^1.7.0, es-abstract@^1.9.0:
+es-abstract@^1.10.0, es-abstract@^1.4.3, es-abstract@^1.5.1, es-abstract@^1.6.1, es-abstract@^1.9.0:
version "1.11.0"
resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.11.0.tgz#cce87d518f0496893b1a30cd8461835535480681"
dependencies:
@@ -3185,6 +3189,16 @@ es-abstract@^1.10.0, es-abstract@^1.4.3, es-abstract@^1.5.1, es-abstract@^1.6.1,
is-callable "^1.1.3"
is-regex "^1.0.4"
+es-abstract@^1.7.0:
+ version "1.12.0"
+ resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.12.0.tgz#9dbbdd27c6856f0001421ca18782d786bf8a6165"
+ dependencies:
+ es-to-primitive "^1.1.1"
+ function-bind "^1.1.1"
+ has "^1.0.1"
+ is-callable "^1.1.3"
+ is-regex "^1.0.4"
+
es-to-primitive@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.1.1.tgz#45355248a88979034b6792e19bb81f2b7975dd0d"
@@ -3360,9 +3374,9 @@ eslint-plugin-import@2.8.0:
minimatch "^3.0.3"
read-pkg-up "^2.0.0"
-eslint-plugin-jsx-a11y@5.1.1:
- version "5.1.1"
- resolved "https://registry.yarnpkg.com/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-5.1.1.tgz#5c96bb5186ca14e94db1095ff59b3e2bd94069b1"
+eslint-plugin-jsx-a11y@^6.0.3:
+ version "6.0.3"
+ resolved "https://registry.yarnpkg.com/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.0.3.tgz#54583d1ae442483162e040e13cc31865465100e5"
dependencies:
aria-query "^0.7.0"
array-includes "^3.0.3"
@@ -3370,7 +3384,7 @@ eslint-plugin-jsx-a11y@5.1.1:
axobject-query "^0.1.0"
damerau-levenshtein "^1.0.0"
emoji-regex "^6.1.0"
- jsx-ast-utils "^1.4.0"
+ jsx-ast-utils "^2.0.0"
eslint-plugin-react@7.4.0:
version "7.4.0"
@@ -3931,6 +3945,10 @@ fs-minipass@^1.2.5:
dependencies:
minipass "^2.2.1"
+fs-readdir-recursive@^1.0.0:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/fs-readdir-recursive/-/fs-readdir-recursive-1.1.0.tgz#e32fc030a2ccee44a6b5371308da54be0b397d27"
+
fs-write-stream-atomic@^1.0.8:
version "1.0.10"
resolved "https://registry.yarnpkg.com/fs-write-stream-atomic/-/fs-write-stream-atomic-1.0.10.tgz#b47df53493ef911df75731e70a9ded0189db40c9"
@@ -4144,7 +4162,7 @@ got@^6.7.1:
unzip-response "^2.0.1"
url-parse-lax "^1.0.0"
-graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9:
+graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.4, graceful-fs@^4.1.6, graceful-fs@^4.1.9:
version "4.1.11"
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658"
@@ -4237,10 +4255,10 @@ has-values@^1.0.0:
kind-of "^4.0.0"
has@^1.0.1:
- version "1.0.1"
- resolved "https://registry.yarnpkg.com/has/-/has-1.0.1.tgz#8461733f538b0837c9361e39a9ab9e9704dc2f28"
+ version "1.0.3"
+ resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796"
dependencies:
- function-bind "^1.0.2"
+ function-bind "^1.1.1"
hash-base@^3.0.0:
version "3.0.4"
@@ -4295,7 +4313,7 @@ hoist-non-react-statics@1.x.x, hoist-non-react-statics@^1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-1.2.0.tgz#aa448cf0986d55cc40773b17174b7dd066cb7cfb"
-hoist-non-react-statics@^2.3.0, hoist-non-react-statics@^2.5.0:
+hoist-non-react-statics@^2.2.1, hoist-non-react-statics@^2.5.0:
version "2.5.0"
resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-2.5.0.tgz#d2ca2dfc19c5a91c5a6615ce8e564ef0347e2a40"
@@ -5431,10 +5449,6 @@ jsprim@^1.2.2:
json-schema "0.2.3"
verror "1.10.0"
-jsx-ast-utils@^1.4.0:
- version "1.4.1"
- resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-1.4.1.tgz#3867213e8dd79bf1e8f2300c0cfc1efb182c0df1"
-
jsx-ast-utils@^2.0.0:
version "2.0.1"
resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-2.0.1.tgz#e801b1b39985e20fffc87b40e3748080e2dcac7f"
@@ -6409,6 +6423,14 @@ osenv@^0.1.4:
os-homedir "^1.0.0"
os-tmpdir "^1.0.0"
+output-file-sync@^1.1.2:
+ version "1.1.2"
+ resolved "https://registry.yarnpkg.com/output-file-sync/-/output-file-sync-1.1.2.tgz#d0a33eefe61a205facb90092e826598d5245ce76"
+ dependencies:
+ graceful-fs "^4.1.4"
+ mkdirp "^0.5.1"
+ object-assign "^4.1.0"
+
p-finally@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae"
@@ -6994,7 +7016,7 @@ pretty-format@^22.4.3:
ansi-regex "^3.0.0"
ansi-styles "^3.2.0"
-private@^0.1.6, private@^0.1.7, private@^0.1.8, private@~0.1.5:
+private@^0.1.6, private@^0.1.8, private@~0.1.5:
version "0.1.8"
resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff"
@@ -7386,33 +7408,6 @@ react-redux@^5.0.7:
loose-envify "^1.1.0"
prop-types "^15.6.0"
-react-router-dom@^4.2.2:
- version "4.2.2"
- resolved "https://registry.yarnpkg.com/react-router-dom/-/react-router-dom-4.2.2.tgz#c8a81df3adc58bba8a76782e946cbd4eae649b8d"
- dependencies:
- history "^4.7.2"
- invariant "^2.2.2"
- loose-envify "^1.3.1"
- prop-types "^15.5.4"
- react-router "^4.2.0"
- warning "^3.0.0"
-
-react-router-redux@^4.0.8:
- version "4.0.8"
- resolved "https://registry.yarnpkg.com/react-router-redux/-/react-router-redux-4.0.8.tgz#227403596b5151e182377dab835b5d45f0f8054e"
-
-react-router@^4.2.0:
- version "4.2.0"
- resolved "https://registry.yarnpkg.com/react-router/-/react-router-4.2.0.tgz#61f7b3e3770daeb24062dae3eedef1b054155986"
- dependencies:
- history "^4.7.2"
- hoist-non-react-statics "^2.3.0"
- invariant "^2.2.2"
- loose-envify "^1.3.1"
- path-to-regexp "^1.7.0"
- prop-types "^15.5.4"
- warning "^3.0.0"
-
react-side-effect@^1.1.0:
version "1.1.5"
resolved "https://registry.yarnpkg.com/react-side-effect/-/react-side-effect-1.1.5.tgz#f26059e50ed9c626d91d661b9f3c8bb38cd0ff2d"
@@ -7480,6 +7475,13 @@ react-treebeard@^2.1.0:
shallowequal "^0.2.2"
velocity-react "^1.3.1"
+react-universal-component@^2.9.0:
+ version "2.9.0"
+ resolved "https://registry.yarnpkg.com/react-universal-component/-/react-universal-component-2.9.0.tgz#75e8d418e6611e43cdbabe5a6c5dab8870c12e30"
+ dependencies:
+ hoist-non-react-statics "^2.2.1"
+ prop-types "^15.5.10"
+
react@^16.3.2:
version "16.3.2"
resolved "https://registry.yarnpkg.com/react/-/react-16.3.2.tgz#fdc8420398533a1e58872f59091b272ce2f91ea9"
@@ -7622,6 +7624,12 @@ reduce-function-call@^1.0.1:
dependencies:
balanced-match "^0.4.2"
+redux-first-router@^0.0.16-next:
+ version "0.0.16-next"
+ resolved "https://registry.yarnpkg.com/redux-first-router/-/redux-first-router-0.0.16-next.tgz#493c344dd92b4c20a318a024d4dfa7d948d87d86"
+ dependencies:
+ rudy-match-path "^0.3.0"
+
redux-logger@^3.0.6:
version "3.0.6"
resolved "https://registry.yarnpkg.com/redux-logger/-/redux-logger-3.0.6.tgz#f7555966f3098f3c88604c449cf0baf5778274bf"
@@ -7652,6 +7660,10 @@ regenerate@^1.2.1:
version "1.3.3"
resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.3.3.tgz#0c336d3980553d755c39b586ae3b20aa49c82b7f"
+regenerator-runtime@^0.10.5:
+ version "0.10.5"
+ resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.10.5.tgz#336c3efc1220adcedda2c9fab67b5a7955a33658"
+
regenerator-runtime@^0.11.0:
version "0.11.1"
resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz#be05ad7f9bf7d22e056f9726cee5017fbf19e2e9"
@@ -7884,6 +7896,12 @@ rst-selector-parser@^2.2.3:
lodash.flattendeep "^4.4.0"
nearley "^2.7.10"
+rudy-match-path@^0.3.0:
+ version "0.3.0"
+ resolved "https://registry.yarnpkg.com/rudy-match-path/-/rudy-match-path-0.3.0.tgz#c90e23caac500f244d5e4ab448e2725f1254e2e8"
+ dependencies:
+ path-to-regexp "^1.7.0"
+
run-async@^2.2.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0"
@@ -8681,6 +8699,10 @@ to-fast-properties@^1.0.3:
version "1.0.3"
resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-1.0.3.tgz#b83571fa4d8c25b82e231b06e3a3055de4ca1a47"
+to-fast-properties@^2.0.0:
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e"
+
to-object-path@^0.3.0:
version "0.3.0"
resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af"
@@ -8958,6 +8980,10 @@ use@^3.1.0:
dependencies:
kind-of "^6.0.2"
+user-home@^1.1.1:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/user-home/-/user-home-1.1.1.tgz#2b5be23a32b63a7c9deb8d0f28d485724a3df190"
+
util-deprecate@^1.0.2, util-deprecate@~1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf"
@@ -8988,6 +9014,12 @@ uuid@^3.1.0, uuid@^3.2.1:
version "3.2.1"
resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.2.1.tgz#12c528bb9d58d0b9265d9a2f6f0fe8be17ff1f14"
+v8flags@^2.1.1:
+ version "2.1.1"
+ resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-2.1.1.tgz#aab1a1fa30d45f88dd321148875ac02c0b55e5b4"
+ dependencies:
+ user-home "^1.1.1"
+
validate-npm-package-license@^3.0.1:
version "3.0.3"
resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.3.tgz#81643bcbef1bdfecd4623793dc4648948ba98338"