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

[Feature?]: Add ability to add/modify head classes, lang and lang dir #1589

Open
2 tasks done
BaseCrusher opened this issue Jul 24, 2024 · 1 comment
Open
2 tasks done
Labels
enhancement New feature or request

Comments

@BaseCrusher
Copy link

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Summary 💡

Currently, the server component contains the basic outline of a page including the head element. This as far as I have seen, makes it impossible to change the classes, lang and lang dir reactively. I think this should be provided as pseudo component, though I don't know, if solid-meta would be better for this feature. But open for other ideas.

Examples 🌈

Not needed.

Motivation 🔦

I wanted to build a website with multilang support as well as the ability to have dark and light mode. My current solution is to add some static scripts to the head section of the server component and calling a function provided there.

@BaseCrusher BaseCrusher added the enhancement New feature or request label Jul 24, 2024
@ryansolid
Copy link
Member

I do think something like Solid Meta would be better.. or something in Solid itself. Right now as you said you have to write it into the document and then create an effect that writes to it after the fact in the client to do updates. It would be nice to streamline this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants