react-loader
Advanced tools
Comparing version 2.3.0 to 2.4.0
@@ -26,2 +26,3 @@ (function (root, factory) { | ||
loadedClassName: React.PropTypes.string, | ||
opacity: React.PropTypes.number, | ||
options: React.PropTypes.object, | ||
@@ -89,3 +90,9 @@ parentClassName: React.PropTypes.string, | ||
spin: function () { | ||
if (this.isMounted() && !this.state.loaded) { | ||
var canUseDOM = !!( | ||
typeof window !== 'undefined' && | ||
window.document && | ||
window.document.createElement | ||
); | ||
if (canUseDOM && this.isMounted() && !this.state.loaded) { | ||
var spinner = new Spinner(this.state.options); | ||
@@ -92,0 +99,0 @@ var target = ReactDOM.findDOMNode(this.refs.loader); |
@@ -26,2 +26,3 @@ (function (root, factory) { | ||
loadedClassName: React.PropTypes.string, | ||
opacity: React.PropTypes.number, | ||
options: React.PropTypes.object, | ||
@@ -89,3 +90,9 @@ parentClassName: React.PropTypes.string, | ||
spin: function () { | ||
if (this.isMounted() && !this.state.loaded) { | ||
var canUseDOM = !!( | ||
typeof window !== 'undefined' && | ||
window.document && | ||
window.document.createElement | ||
); | ||
if (canUseDOM && this.isMounted() && !this.state.loaded) { | ||
var spinner = new Spinner(this.state.options); | ||
@@ -92,0 +99,0 @@ var target = ReactDOM.findDOMNode(this.refs.loader); |
{ | ||
"name": "react-loader", | ||
"description": "React component that displays a spinner via spin.js until your component is loaded", | ||
"version": "2.3.0", | ||
"version": "2.4.0", | ||
"main": "lib/react-loader.js", | ||
@@ -6,0 +6,0 @@ "scripts": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
18567
306