In this app we will see how to use Polymer elements in a React project.
To use Polymer elements in your React application, you must implement Polymer elements in the public folder of the React application!
After creating your polymer element, import it into the index.html
file
<link rel="import" href="src/my-main-element/my-main-element.html">
And now, you just need to use your element in your React component (in our case we used it in the App.js
)
function App() { return ( <my-main-element></my-main-element> ); }
Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.