freeCodeCamp/tools/challenge-parser/parser/__fixtures__/ast-empty-html.json

167 lines
4.2 KiB
JSON

{
"type": "root",
"children": [
{
"type": "heading",
"depth": 1,
"children": [
{
"type": "text",
"value": "--seed--",
"position": {
"start": { "line": 1, "column": 3, "offset": 2 },
"end": { "line": 1, "column": 11, "offset": 10 },
"indent": []
}
}
],
"position": {
"start": { "line": 1, "column": 1, "offset": 0 },
"end": { "line": 1, "column": 11, "offset": 10 },
"indent": []
}
},
{
"type": "heading",
"depth": 2,
"children": [
{
"type": "text",
"value": "--before-user-code--",
"position": {
"start": { "line": 3, "column": 4, "offset": 15 },
"end": { "line": 3, "column": 24, "offset": 35 },
"indent": []
}
}
],
"position": {
"start": { "line": 3, "column": 1, "offset": 12 },
"end": { "line": 3, "column": 24, "offset": 35 },
"indent": []
}
},
{
"type": "code",
"lang": "css",
"meta": null,
"value": "body {\n etc: ''\n}",
"position": {
"start": { "line": 5, "column": 1, "offset": 37 },
"end": { "line": 9, "column": 4, "offset": 66 },
"indent": [1, 1, 1, 1]
}
},
{
"type": "code",
"lang": "html",
"meta": null,
"value": "",
"position": {
"start": { "line": 11, "column": 1, "offset": 68 },
"end": { "line": 12, "column": 4, "offset": 79 },
"indent": [1]
}
},
{
"type": "heading",
"depth": 2,
"children": [
{
"type": "text",
"value": "--seed-contents--",
"position": {
"start": { "line": 14, "column": 4, "offset": 84 },
"end": { "line": 14, "column": 21, "offset": 101 },
"indent": []
}
}
],
"position": {
"start": { "line": 14, "column": 1, "offset": 81 },
"end": { "line": 14, "column": 21, "offset": 101 },
"indent": []
}
},
{
"type": "code",
"lang": "html",
"meta": null,
"value": "<html>\n <body>\n </body>\n</html>",
"position": {
"start": { "line": 16, "column": 1, "offset": 103 },
"end": { "line": 21, "column": 4, "offset": 148 },
"indent": [1, 1, 1, 1, 1]
}
},
{
"type": "code",
"lang": "css",
"meta": null,
"value": "body {\n background: green;\n}",
"position": {
"start": { "line": 23, "column": 1, "offset": 150 },
"end": { "line": 27, "column": 4, "offset": 190 },
"indent": [1, 1, 1, 1]
}
},
{
"type": "code",
"lang": "js",
"meta": null,
"value": "var x = 'y';",
"position": {
"start": { "line": 29, "column": 1, "offset": 192 },
"end": { "line": 31, "column": 4, "offset": 214 },
"indent": [1, 1]
}
},
{
"type": "heading",
"depth": 2,
"children": [
{
"type": "text",
"value": "--after-user-code--",
"position": {
"start": { "line": 33, "column": 4, "offset": 219 },
"end": { "line": 33, "column": 23, "offset": 238 },
"indent": []
}
}
],
"position": {
"start": { "line": 33, "column": 1, "offset": 216 },
"end": { "line": 33, "column": 23, "offset": 238 },
"indent": []
}
},
{
"type": "code",
"lang": "css",
"meta": null,
"value": "body {\n background: blue;\n}",
"position": {
"start": { "line": 35, "column": 1, "offset": 240 },
"end": { "line": 39, "column": 4, "offset": 279 },
"indent": [1, 1, 1, 1]
}
},
{
"type": "code",
"lang": "js",
"meta": null,
"value": "function teardown(params) {\n // after\n}",
"position": {
"start": { "line": 41, "column": 1, "offset": 281 },
"end": { "line": 45, "column": 4, "offset": 331 },
"indent": [1, 1, 1, 1]
}
}
],
"position": {
"start": { "line": 1, "column": 1, "offset": 0 },
"end": { "line": 46, "column": 1, "offset": 332 }
}
}