Reputation: 1564
I will be building an app that is suppose to be serving as a widget and i wanted to use react to do so, but i just started with react, i created app using "Create React App", i made some components and i have working prototype in development environment but ...
The guys asked that they will give me an id
of a container where widget should be placed and they are asking for css
and js
links and they expect widget to be build in there.
I started inspecting my environment and i kind of dont know where to start, in sources i see that there is gazilion packages connected and some 40k lines bundle.js file.
Is it possible that the customer on his website just puts:
<link rel="stylesheet" type="text/css" href="__LINK_TO_SERVER__app.css">
<div id="app-widget"><!-- APP WILL BE HERE --></div>
<script src="__LINK_TO_SERVER__/app.js"></script>
and this app will be working?
If so, what are the steps to make it to work?
Upvotes: 0
Views: 60
Reputation: 15216
<link rel="stylesheet">
insertion into your js bundleasync
option: <script async src="__LINK_TO_SERVER__/app.js"></script>
Upvotes: 1