auth0-extensions/auth0-sso-dashboard-extension

View on GitHub
client/showDevTools.jsx

Summary

Maintainability
A
0 mins
Test Coverage
import React from 'react';
import { render } from 'react-dom';
import DevTools from './containers/DevTools';

module.exports = (store) => {
  const popup = window.open(null, 'Redux DevTools', 'menubar=no,location=no,resizable=yes,scrollbars=no,status=no');
  if (!popup) {
    return;
  }

  popup.location.reload();

  setTimeout(() => {
    popup.document.write('<div id="react-devtools-root"></div>');
    render(
      <DevTools store={store} />,
      popup.document.getElementById('react-devtools-root')
    );
  }, 10);
};