Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compose with redux dev tools in development mode only #1085

Merged
merged 3 commits into from
Jan 30, 2019

Conversation

teleaziz
Copy link
Contributor

No description provided.

const composeEnhancers =
typeof window !== 'undefined' && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__
isDevelopment &&
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

process.env.NODE_ENV !== 'production'

Sometimes there are other env strings used that are not development such as 'test'

@@ -20,8 +20,12 @@ import type { Store } from './store-types';
// We are checking if window is available before using it.
// This is needed for universal apps that render the component server side.
// Details: https://github.com/zalmoxisus/redux-devtools-extension#12-advanced-store-setup
const isDevelopment: boolean = process.env.NODE_ENV === 'development';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
const isDevelopment: boolean = process.env.NODE_ENV === 'development';

const composeEnhancers =
typeof window !== 'undefined' && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__
isDevelopment &&
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
isDevelopment &&
process.env.NODE_ENV !== 'production' &&

@alexreardon
Copy link
Collaborator

Thanks!!!

@alexreardon alexreardon merged commit adc5a2e into atlassian:master Jan 30, 2019
@alexreardon
Copy link
Collaborator

This will go out in the next release (some time in the next two weeks 🤞 )

@teleaziz teleaziz deleted the patch-1 branch January 30, 2019 23:19
@teleaziz
Copy link
Contributor Author

Thanks @alexreardon for taking a look, great work on this package btw 🥇

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants