I have purchased an HTML admin template from themeforest (https://themeforest.net/item/limitless-responsive-web-application-kit/13080328?s_rank=1).
I am building a MERN stack site, and wondering what would be the best way to convert this HTML template to a react site. Breaking down the template to components, adding routes manually, and converting HTML to JSX etc seems to be a tedious task.
The question arises because in themeforest, the most popular admin templates were built for a jQuery / HTML world, not for a full stack JS world. For example, the theme that I've linked above has ~7000 downloads. These templates upon purchase give you a whole bunch of HTML and CSS, and if we have to build a react site out of these, then manually converting the HTML to JSX, and breaking it down to componenets, is a laborious process. Wondering if there's a better approach to solving this problem.
You can use html-to-react-components
A better approach would be converted your html to jsx and use in your react-component. You can converted your html to jsx here.
You can use:
In the long run however, it is better if you can split out these templates into a granular set of components with well defined roles.
http://www.htmltoreact.com here you can convert your html syntax into jsx(reactjs) syntax.
来源:https://stackoverflow.com/questions/47370369/how-to-convert-a-html-template-to-react