When clicking on a entry in the listing, a console error would be logged
by `history` (react-router): "Hash history cannot push state; it is
ignored". This was caused because using `bind` in the click handler
caused the return value to be passed to the `history.push` as the second
param. This was ignored in react-router v2, but gives a warning in v4.
Change suggested by @aquibm, thank you!
This is changed as of React 16:
When replacing `<A />` with `<B />`, `B.componentWillMount` now always
happens before `A.componentWillUnmount`. Previously,
`A.componentWillUnmount` could fire first in some cases.
This allows only the transpilation needed for the supported browsers to
be done. It also allows us to use the upgrades from ES2016 and ES2017
without needing to add a seperate preset.
* Move supported browser list to package.json.
That way all build tools can use it.
* Specify supported browsers explicitly.
This is necessary for the latest version of browserslist/autoprefixer.
This also drops IE 10 support, as it was accidental anyway.
* Upgrade PostCSS build deps.
This was breaking some sites that depended on the CMS because they were
accidentally using storybook's deps instead of adding them as their own
(particularly the babel presets). We are going to hold off on this until
the next version so that we can add a release warning.
This reverts commit 4634918001e474ec2f195fbdddae18591d3207ab.
If the backend was changed in the config, the user from the old backend
would be passed to the new backend, which could cause errors if the
format was different.
Before, if the CMS was loading user OAuth credentials from
`localStorage`, then user write access would not be checked again.
However, the `config.yml` repo could be changed, which would cause the
user to be still logged in even if they did not have write permissions.
Also, if the user had updated their metadata (avatar, etc.), the CMS
would not update that either.