End parameter of Anchor object vs stop parameter of fixedTable method

I’d like to understand better the difference between those two parameters. I have the following Sensible field config and I’m not sure if having both are useful/needed. I’d like to avoid redundancy in my config if possible.

{
      "id": "notes_and_applicable_endorsements",
      "type": "table",
      "anchor": {
        "match": {
          "text": "NOTES AND APPLICABLE ENDORSEMENTS",
          "type": "equals"
        },
        "end": {
          "text": "TERMS AND CONDITIONS",
          "type": "equals"
        }
      },
      "method": {
        "id": "fixedTable",
        "columnCount": 2,
        "columns": [
          {
            "id": "endorsement_title",
            "index": 1,
            "type": "string",
            "isRequired": true
          }
        ],
        "stop": {
          "type": "equals",
          "text": "TERMS AND CONDITIONS"
        }
      }
    }

Hi! So an anchor object defines the place where Sensible starts looking for a table, and then the stop parameter inside the fixed table defines where Sensible stops looking for a table. Generally speaking, the anchor’s end parameter is often optional, but the table’s stop parameter is always recommended.

In more details: within the anchor object, the end parameter specifies where in the doc to stop looking for the anchor match. The anchor’s end parameter (and start parameter) are generally useful if there are multiple anchor match candidates and you need to narrow down where in the doc to look for the anchor.

On the other hand, the table stop parameter is always recommended. Without it, Sensible searches all pages after the anchor for tables, which can impact performance.

To learn more, see the docs:

anchor

fixed table

(and if you’re really curious, anchor nuances covers advanced concepts of anchor arrays versus anchor start and stop, for when it’s really tricky to match an anchor).

let me know if you have more questions!

1 Like