makeStringIndex function

dynamic makeStringIndex(
  1. dynamic strings
)

Implementation

makeStringIndex(strings) {
  var t = Record('String INDEX', [
    {"name": 'strings', "type": 'INDEX', "value": []}
  ], null);
  t.strings = [];
  for (var i = 0; i < strings.length; i += 1) {
    t.strings.push({"name": 'string_${i}', "type": 'STRING', "value": strings[i]});
  }

  return t;
}