I thank you for your response.
But the documentation and examples are full of jQuery snippets and is incomplete.
Only in the jQuery documentation can i find JqxDataAdapter API reference and is not clear how to use it in React.
I tried:
// prepare the data
let source =
{
datatype: 'json',
datafields: [
{name: 'id'},
{name: 'parentid'},
{name: 'text'},
{name: 'subMenuWidth'}
],
id: 'id',
localdata: data
};
// create data adapter.
let dataAdapter = React.createElement(JqxDataAdapter, source);
// perform Data Binding.
dataAdapter.dataBind();
And i get “Warning: React.createElement: type is invalid” error.
I don’t get where to import it from.
I tried with:
import JqxDataAdapter from './assets/jqwidgets/jqxdata.js';
and
import JqxDataAdapter from './assets/jqwidgets/jqx-all.js';