swc/crates/swc_html_parser/tests/fixture/document/output.json

136 lines
3.2 KiB
JSON

{
"type": "Document",
"span": {
"start": 1,
"end": 103
},
"mode": "no-quirks",
"children": [
{
"type": "DocumentType",
"span": {
"start": 1,
"end": 16
},
"name": "html",
"publicId": null,
"systemId": null,
"raw": "<!DOCTYPE html>"
},
{
"type": "Element",
"span": {
"start": 17,
"end": 103
},
"tagName": "html",
"namespace": "http://www.w3.org/1999/xhtml",
"attributes": [],
"children": [
{
"type": "Element",
"span": {
"start": 0,
"end": 0
},
"tagName": "head",
"namespace": "http://www.w3.org/1999/xhtml",
"attributes": [],
"children": [],
"content": null,
"isSelfClosing": false
},
{
"type": "Element",
"span": {
"start": 24,
"end": 103
},
"tagName": "body",
"namespace": "http://www.w3.org/1999/xhtml",
"attributes": [],
"children": [
{
"type": "Text",
"span": {
"start": 30,
"end": 32
},
"data": "\n\n",
"raw": "\n\n"
},
{
"type": "Element",
"span": {
"start": 32,
"end": 57
},
"tagName": "h1",
"namespace": "http://www.w3.org/1999/xhtml",
"attributes": [],
"children": [
{
"type": "Text",
"span": {
"start": 36,
"end": 52
},
"data": "My First Heading",
"raw": "My First Heading"
}
],
"content": null,
"isSelfClosing": false
},
{
"type": "Text",
"span": {
"start": 57,
"end": 59
},
"data": "\n\n",
"raw": "\n\n"
},
{
"type": "Element",
"span": {
"start": 59,
"end": 85
},
"tagName": "p",
"namespace": "http://www.w3.org/1999/xhtml",
"attributes": [],
"children": [
{
"type": "Text",
"span": {
"start": 62,
"end": 81
},
"data": "My first paragraph.",
"raw": "My first paragraph."
}
],
"content": null,
"isSelfClosing": false
},
{
"type": "Text",
"span": {
"start": 85,
"end": 103
},
"data": "\n\n\n\n",
"raw": "\n\n\n\n"
}
],
"content": null,
"isSelfClosing": false
}
],
"content": null,
"isSelfClosing": false
}
]
}