-
-
Notifications
You must be signed in to change notification settings - Fork 47
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
using null to remove an existing head tag #179
Comments
This should actually be the behavior, will look at fixing it, specifically passing Thanks! |
I agree, this would be a very helpful feature! I use hid's to override meta tags on each page, and when the values of these tags are null it creates an undefined tag, rather than ignoring them completely and defaulting to the tags at the global level. Any updates on this feature? Thanks |
Oh ye I forgot to update this, with the latest version (1.7.2) this will remove the meta tag . Let me know if you have any issues with it. |
It works according to one definition.
And unhead has a meta tag definition of
You could say that the null should remove the original og:image defined in html. In the case of current unhead logic, it's treating the null as more of a "fallback to whatever was in original html" As such, there's not an "easy" way to remove original html meta tags from unhead. The workaround is to remove them "manually" upon unhead initialization. |
Good point, have moved to this issue to track #232 |
Describe the feature
When doing something like
it actually creates
I was attempting to use
null
as a means of "unsetting" the meta property, but obviously it did not work. The same happens withundefined
.Not sure if this creates other problems of deduplication, etc., but it would be nice if this worked.
The specific use case is removing a meta tag that's defined in index.html outside of unhead.js... unhead will REPLACE existing head tags, but to remove?? not sure
Additional information
The text was updated successfully, but these errors were encountered: