AgGrid: getting the data type of a column or cell

You should be making sure that your component always has a json encoded string in the children, otherwise the callback should fail, as this is expected.

ok, took your suggestions. Now

store_props = {
    "children":
    [
        '{"row_format":{"field1":"str", "field2":0.0}, "selector_field":"field1"}'
    ]
}

and in the callback I do:

row_info = json.loads(store)
field = row_info["selector_field"]
try:
    field_dtype = getattr(__builtins__,row_info["row_format"][field])
except AttributeError:
    field_dtype = str
default_row = row_info["row_format"].copy()

where store comes from State(ids.store(MATCH),"children")

Thank you @AnnMarieW and @jinnyzor for all of your suggestions!

2 Likes