Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set class and id for components #183

Open
pandaulait opened this issue Aug 28, 2023 · 0 comments
Open

Set class and id for components #183

pandaulait opened this issue Aug 28, 2023 · 0 comments

Comments

@pandaulait
Copy link

Is your feature request related to a problem? Please describe.
There were cases where I wanted to set a class or id on the component itself, as shown below

<ButtonComponent class="mt-10"></ButtonComponent>

<SectionComponent id="about"></SectionComponent>

Describe the solution you'd like
I'm implementing the following as a workaround right now, so it would be easier to use if you could specify class and id to the component

<SectionComponent>
  <div id="about">...  </div>
</SectionComponent>

However, in order to consider the pros and cons of this issue, we would need to review the current specification that allows multiple elements to be set in the root of a component

<!-- SectionComponent.spear-- >
<div></div>
<div></div>
...

<!-- SectionComponent.spear-- >
<div></div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant