react-instagram-embed
Advanced tools
Comparing version 1.0.0 to 1.1.0
@@ -15,5 +15,5 @@ 'use strict'; | ||
var _jsonpPromise = require('jsonp-promise'); | ||
var _jsonpP = require('jsonp-p'); | ||
var _jsonpPromise2 = _interopRequireDefault(_jsonpPromise); | ||
var _jsonpP2 = _interopRequireDefault(_jsonpP); | ||
@@ -58,2 +58,6 @@ var _queryString = require('query-string'); | ||
_this2.cancel = function () { | ||
return _this2.jsonp.cancel(); | ||
}; | ||
return _this2; | ||
@@ -148,3 +152,3 @@ } | ||
} | ||
}, 10); | ||
}, 20); | ||
})(_this4); | ||
@@ -156,3 +160,3 @@ }); | ||
value: function fetchEmbed(queryParams) { | ||
this.jsonp = (0, _jsonpPromise2.default)('https://api.instagram.com/oembed/?' + queryParams); | ||
this.jsonp = (0, _jsonpP2.default)('https://api.instagram.com/oembed/?' + queryParams); | ||
this.props.onLoading && this.props.onLoading(); | ||
@@ -175,2 +179,5 @@ this.jsonp.promise.then(this.handleFetchSuccess).catch(this.handleFetchFailure); | ||
} | ||
// Public | ||
}]); | ||
@@ -177,0 +184,0 @@ |
{ | ||
"name": "react-instagram-embed", | ||
"version": "1.0.0", | ||
"version": "1.1.0", | ||
"description": "React embedding Instagram posts component", | ||
@@ -16,3 +16,3 @@ "main": "lib/index.js", | ||
"flow": "flow", | ||
"docs": "npm run predocs && NODE_ENV=docs webpack", | ||
"docs": "npm run predocs && NODE_ENV=production webpack", | ||
"clean:docs": "if [ -d docs ]; then rm -rf docs; fi", | ||
@@ -38,3 +38,3 @@ "predocs": "npm run clean:docs; mkdir docs && npm run favicon", | ||
"dependencies": { | ||
"jsonp-promise": "^0.1.2", | ||
"jsonp-p": "^2.0.0", | ||
"query-string": "^4.2.3" | ||
@@ -60,4 +60,4 @@ }, | ||
"flow-bin": "^0.33.0", | ||
"highlight.js": "^9.7.0", | ||
"html-webpack-plugin": "^2.24.0", | ||
"insert-css": "^1.0.0", | ||
"insert-stylesheet": "^0.1.0", | ||
@@ -64,0 +64,0 @@ "jest": "^16.0.2", |
@@ -26,2 +26,3 @@ # react-instagram-embed | ||
hideCaption | ||
containerTagName='div' | ||
onLoading={() => {}} | ||
@@ -38,2 +39,3 @@ onSuccess={() => {}} | ||
- `hideCaption` {Boolean} Default `false` | ||
- `containerTagName` {String} Default `div` | ||
- `onLoading` {Function} | ||
@@ -40,0 +42,0 @@ - `onSuccess` {Function} |
11767
151
67
+ Addedjsonp-p@^2.0.0
+ Addeddebug@2.6.9(transitive)
+ Addedjsonp@0.2.1(transitive)
+ Addedjsonp-p@2.0.0(transitive)
+ Addedms@2.0.0(transitive)
- Removedjsonp-promise@^0.1.2
- Removedjsonp-promise@0.1.2(transitive)