I was thinking through the same problem last week and i solved it like this. Start out with your datatype set to a function, that loads your initial data via “$table[0].addJSONData(initialResults)”, and then make that same function overwrite the datatype property [itself].
var url = “/researchCatalog/Search/ProviderGridData/”;
var gridData = getGridData(url, searchParams)
var colModel = gridData.colModel;
var initialResults = gridData.initialResults;
var datatype = function() {