Skip to content

Support multi-line component props? #299

Description

@xMrAfonso

PS: I did message Sebastien on X, but I thought this would be a better place to ask this. It's not necessarily a feature request, it's rather a question on why it's not a thing.

Currently, component attributes seem limited to a single line:

::component{foo="bar" hello="world"}
::

Could comark support multi-line attributes like this?

::component{
  foo="bar"
  hello="world"
}
::

I know YAML props exist, but several users find that syntax verbose and overall unpleasant to work with. Additionally, would love to know more on the reasons why this isn't already a thing, or what the limitations are.

It would be nice to also maybe have an props attribute which I can insert yaml directly. For instance:

::component{ props="|
  foo: "bar"
  hello: "world"
"}
::

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