aboutsummaryrefslogtreecommitdiff
path: root/node_modules/domhandler/test/cases/01-basic.json
blob: e7952ec9e2e17aef54d4155527ed910f8c9a94a1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
{
  "name": "Basic test",
  "options": {},
  "html": "<!DOCTYPE html><html><title>The Title</title><body>Hello world</body></html>",
  "expected": [
    {
      "name": "!doctype",
      "data": "!DOCTYPE html",
      "type": "directive"
    },
    {
      "type": "tag",
      "name": "html",
      "attribs": {},
      "children": [
        {
          "type": "tag",
          "name": "title",
          "attribs": {},
          "children": [
            {
              "data": "The Title",
              "type": "text"
            }
          ]
        },
        {
          "type": "tag",
          "name": "body",
          "attribs": {},
          "children": [
            {
              "data": "Hello world",
              "type": "text"
            }
          ]
        }
      ]
    }
  ]
}