Table of Contents macro can fail to render all headings if the page takes long enough to load

XMLWordPrintable

    • 3
    • Severity 3 - Minor

      Summary

      The Table of Contents macro runs client-side and so needs to wait for the page to load before calculating which headings to render. It's currently a flat "Wait 500ms", so if the page is large enough, the ToC macro will start its calculations before the page is fully loaded, and you can end up with a differing number of headings showing on each page reload.

      Steps to reproduce

      1. Create a large page (300KB+) with a number of headings (10+).
      2. Add the Table of Contents macro at the top.
      3. Refresh the page a bunch of times.

      Expected results

      The ToC macro always shows the correct number of headings given on the page.

      Actual results

      Depending on how long the page takes to load, the ToC macro will show differing numbers of headings.

            Assignee:
            Unassigned
            Reporter:
            Nick Mason
            Votes:
            7 Vote for this issue
            Watchers:
            11 Start watching this issue

              Created:
              Updated:
              Resolved: