swc/css/parser/tests/fixture/esbuild/misc/jbIIxHeXTPO0PtiubVziHQ/output.json
Donny/강동윤 b206404d94
feat(css): Recover from invalid properties (#2312)
swc_css_ast:
 - Add `DeclBlockItem`.
 - Change `DeclBlock.properties` to `DeclBlock.items`.

swc_css_parser:
 - Add a way to recovered errors.
2021-09-28 09:58:56 +00:00

144 lines
3.1 KiB
JSON

{
"type": "Stylesheet",
"span": {
"start": 0,
"end": 58,
"ctxt": 0
},
"rules": [
{
"type": "KeyframesRule",
"span": {
"start": 0,
"end": 58,
"ctxt": 0
},
"id": {
"type": "Text",
"span": {
"start": 11,
"end": 15,
"ctxt": 0
},
"value": "name"
},
"blocks": [
{
"span": {
"start": 18,
"end": 37,
"ctxt": 0
},
"selector": [
{
"type": "Text",
"span": {
"start": 18,
"end": 22,
"ctxt": 0
},
"value": "from"
}
],
"rule": {
"type": "DeclBlock",
"span": {
"start": 23,
"end": 37,
"ctxt": 0
},
"items": [
{
"type": "Property",
"span": {
"start": 25,
"end": 35,
"ctxt": 0
},
"name": {
"type": "Text",
"span": {
"start": 25,
"end": 30,
"ctxt": 0
},
"value": "color"
},
"values": [
{
"type": "Text",
"span": {
"start": 32,
"end": 35,
"ctxt": 0
},
"value": "red"
}
],
"important": null
}
]
}
},
{
"span": {
"start": 38,
"end": 56,
"ctxt": 0
},
"selector": [
{
"type": "Text",
"span": {
"start": 38,
"end": 40,
"ctxt": 0
},
"value": "to"
}
],
"rule": {
"type": "DeclBlock",
"span": {
"start": 41,
"end": 56,
"ctxt": 0
},
"items": [
{
"type": "Property",
"span": {
"start": 43,
"end": 54,
"ctxt": 0
},
"name": {
"type": "Text",
"span": {
"start": 43,
"end": 48,
"ctxt": 0
},
"value": "color"
},
"values": [
{
"type": "Text",
"span": {
"start": 50,
"end": 54,
"ctxt": 0
},
"value": "blue"
}
],
"important": null
}
]
}
}
]
}
]
}