---
agentTools:
  projectIndex: https://nativescript-batch.readme.io/llms.txt
---

# items

Gets the batch wide (observable) array of items.

[block:code]
{
  "codes": [
    {
      "code": "import Batch = require(\"nativescript-batch\");\n\nvar b = Batch.newBatch(function(ctx) {\n    console.log(\"Item #1 => \" + ctx.items.getItem(0));  // 11\n    console.log(\"Item #2 => \" + ctx.items.getItem(1));  // 22\n});\n\nb.items.push(11);\nb.items.push(22);\n\nb.start();",
      "language": "javascript"
    }
  ]
}
[/block]