Skip to content

Commit

Permalink
remove test env checking (I wasn't aware this is not required), close #…
Browse files Browse the repository at this point in the history
  • Loading branch information
dai-shi committed Mar 2, 2020
1 parent 1f17bd6 commit ba7476a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Change Log

## [Unreleased]
### Changed
- Avoid React render warning in test (#15)

## [1.1.0] - 2020-02-24
### Changed
Expand Down
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const CONTEXT_LISTENERS = (
);

const createProvider = (OrigProvider, listeners) => React.memo(({ value, children }) => {
if (process.env.NODE_ENV !== 'production' && process.env.NODE_ENV !== 'test') {
if (process.env.NODE_ENV !== 'production') {
// we use layout effect to eliminate warnings.
// but, this leads tearing with startTransition.
// eslint-disable-next-line react-hooks/rules-of-hooks
Expand Down

0 comments on commit ba7476a

Please sign in to comment.