🔔 Alert..!! Get 2 Month Free Cloud Hosting With $200 Bonus From Digital Ocean ACTIVATE DEAL

A React component for embedding Instagram posts into your web applications.

React Social Media

Documentation

react-instagram-embed

CircleCI npm version License

React embedding Instagram posts component

yarn add react-instagram-embed  # or  npm i react-instagram-embed

Live demo

Usage

import InstagramEmbed from 'react-instagram-embed';  <InstagramEmbed   url='https://instagr.am/p/Zw9o4/'   maxWidth={320}   hideCaption={false}   containerTagName='div'   protocol=''   injectScript   onLoading={() => {}}   onSuccess={() => {}}   onAfterRender={() => {}}   onFailure={() => {}} />

props

  • url {String} Instagram URL. Required
  • maxWidth {Number} Max width. Minimum size is 320. Default undefined
  • hideCaption {Boolean} Default false
  • containerTagName {String} Default 'div'
  • protocol {String} Instagram API script protocol. Default '' same as current protocol
    • This property needed if you use device's file system, for example, Electron, Cordova apps
  • injectScript {Boolean} Default true
  • onLoading {Function}
  • onSuccess {Function}
  • onAfterRender {Function}
  • onFailure {Function}

License

MIT

© sugarshin


You May Also Like