HEX
Server: Apache/2.4.41 (Ubuntu)
System: Linux wordpress-ubuntu-s-2vcpu-4gb-fra1-01 5.4.0-169-generic #187-Ubuntu SMP Thu Nov 23 14:52:28 UTC 2023 x86_64
User: root (0)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //var/www/zaklada/html/node_modules/domhandler/test/cases/25-with-end-indices.json
{
  "name": "withEndIndices adds correct endIndex properties",
  "options": {"withStartIndices": true,"withEndIndices": true},
  "streaming": false,
  "html": "<!DOCTYPE html> <html> <title>The Title</title> <body class='foo'>Hello world <p></p></body> <!-- the comment --> </html> ",
  "expected": [
    {
      "endIndex": null,
      "name": "!doctype",
      "data": "!DOCTYPE html",
      "type": "directive"
    },
    {
      "type": "text",
      "data": " ",
      "endIndex": 15
    },
    {
      "endIndex": 120,
      "type": "tag",
      "name": "html",
      "attribs": {},
      "parent": null,
      "children": [
        {
          "endIndex": 22,
          "type": "text",
          "data": " "
        },
        {
          "endIndex": 46,
          "type": "tag",
          "name": "title",
          "attribs": {},
          "children": [
            {
              "endIndex": 38,
              "data": "The Title",
              "type": "text"
            }
          ]
        },
        {
          "endIndex": 47,
          "type": "text",
          "data": " "
        },
        {
          "endIndex": 91,
          "type": "tag",
          "name": "body",
          "attribs": {"class": "foo"},
          "children": [
            {
              "endIndex": 77,
              "data": "Hello world ",
              "type": "text"
            },
            {
              "endIndex": 84,
              "type": "tag",
              "name": "p",
              "attribs": {},
              "children": []
            }
          ]
        },
        {
          "endIndex": 92,
          "type": "text",
          "data": " "
        },
        {
          "endIndex": 112,
          "type": "comment",
          "data": " the comment "
        },
        {
          "endIndex": 113,
          "type": "text",
          "data": " "
        }
      ]
    }
  ]
}