Skip to content

MDC break when using \' to escape ' inside a v-binded prop #273

@leo91000

Description

@leo91000

To reprodruce :

::foo{:test='{"foo":"I\'d love to}'}
::

Outputs AST :

{
  "type": "root",
  "children": [
    {
      "type": "element",
      "tag": "p",
      "props": {},
      "children": [
        {
          "type": "text",
          "value": "::foo{:test='{\"foo\":\"I'd love to}'}\n::"
        }
      ]
    }
  ]
}

But what is expected :

{
  "type": "root",
  "children": [
    {
      "type": "element",
      "tag": "foo",
      "props": {
        ":test": "{\"foo\":\"I'd love to}"
      },
      "children": []
    }
  ]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions