reactify-json
v0.1.25
Published
Turn a JSON tree to a React Component.
Downloads
9
Readme
This package's goal is simple: obtain a React Component from whatever you receive from jsonify-html.
Usage
- Import the package:
import jsonifyHTML from "jsonify-html";
import ReactifyJSON from "reactify-json";
- Generate a JSON structure from your HTML:
const json =jsonifyHTML.makeJSONfromHTML("<html><body>bruh</body></html>");
- Feed the JSON into the reactifier:
const output = <ReactifyJSON json={json} />
- Profit:
// inside your react component
render() {
return output;
}