I'm trying to work React into my HTML page which I'm trying to create dynamic cards from bootstrap, but I keep getting Here's what I have so far
service.html
<head>
<script src="https://unpkg.com/@babel/standalone/babel.min.js"></script>
</head>
<body>
<div id="services-load"></div>
<script src="https://unpkg.com/react@16/umd/react.production.min.js" crossorigin></script>
<script src="https://unpkg.com/react-dom@16/umd/react-dom.production.min.js" crossorigin></script>
<script type="module" src="rjs.js"></script>
</body>
rjs.js
const e = React.createElement;
import Card from "./services/Cards";
const domContainer = document.querySelector('#services-load');
ReactDOM.render(e(<Card />), domContainer);
Cards.js
import Card from "./CardUI";
import img1 from "../assets/imgs/services/botox.jpg";
import img2 from "../assets/imgs/services/lipo.jpg";
import img3 from "../assets/imgs/services/prp.jpg";
const Card = props => {
return (
<div className="container aesthetic-body">
<div className="row">
<div className="col-lg-4 col-md-4 col-sm-4 col-xs-4">
<Card imgsrc={img1}/>
</div>
<div className="col-lg-4 col-md-4 col-sm-4 col-xs-4">
<Card imgsrc={img2}/>
</div>
<div className="col-lg-4 col-md-4 col-sm-4 col-xs-4">
<Card imgsrc={img3}/>
</div>
</div>
</div>
);
}
export default Card;
CardUI.js
const Card = props => {
return (
<div className="card">
<a href="">
<div className="card-header">BOTOX / FILLERS</div>
<img className="card-img-top" src={props.imgsrc} alt={"Card image cap"}/>
</a>
</div>
);
}
export default Card;
