I am using https://github.com/joeybuczek/react-quicktable in my react application and I am trying to put an <img/>
and <input/>
in one of the the datacells but it is not working.
function MyComponent(props) {
const myDataSet = [
{ Column1: "123456789", Column2: <img src="url" />, "Column3":<input type="text" />},
];
return (
<Fragment>
<QuickTable data={myDataSet}>
<Column name="Column1" />
<Column name="Column2" />
<Column name="Column3" />
</QuickTable>
</Fragment>
);
}
I get ” in the that is rendered. I tried passing a variable like this:
var j = () => {return <img src/>}
var k = () => { return <input type="text" />}
I also tried:
var j = <img src/>
var k = <input type="text"/>