inReactDevMode top-level property
bool
get
inReactDevMode
Whether the "dev" build of react.js is being used.
Useful for creating conditional logic based on whether your application is being served in a production environment.
if (inReactDevMode) {
print('Debug info that only developers should see.');
}
This value will be
true
if your HTML page includesreact.js
orreact_with_addons.js
, andfalse
if your HTML page includesreact_prod.js
orreact_with_react_dom_prod.js
.
Implementation
bool get inReactDevMode => _inReactDevMode;