Things We Can't Do (Yet) with Components

The limitations that you will encounter stem largely from the sandboxed nature of iFrame where a component gets rendered.

  • Your component can’t exit the iFrame. For example, if a complex calculation has just finished and you try to use react-toastify to send a notification to the bottom of the page, the toast will get stuck inside the iFrame instead.

Toastify example

  • Since your component runs inside an iFrame, it can’t access properties of the full app, so you can’t change the app styling or interact with other components on the page. Your component cannot go into the sidebar (yet) or access properties of the parent frame.
  • There are iFrame security policies that may compromise your plans — you can look these up in the source code of the IFrameUtil.ts file. Things like embedding Disqus or cookie access for Twitter may not be permitted in the short term.

Components are still an early release and the Streamlit team is working on alleviating those.