Download / preact-helmet

A document head manager for Preact
MIT License
82 stars 7 forks source link

Support for html tags format #17

Closed siddharthkp closed 7 years ago

siddharthkp commented 7 years ago

Does preact-helmet support html tags like react-helmet?

https://github.com/nfl/react-helmet#example:

<Helmet>
  <meta charSet="utf-8" />
  <title>My Title</title>
  <link rel="canonical" href="http://mysite.com/example" />
</Helmet>
Download commented 7 years ago

Unfortunately, not (yet).

When I ported Helmet it was at 4.x. They added these new features later. I'll probably port the new version at some point but I don't have the time atm. PRs are always welcome of course! ;)

siddharthkp commented 7 years ago

@Download How should I go about it? If I know the diff between the 2 repos, it can hopefully be automated and always be in sync with react-helmet (at least minor versions)

Download commented 7 years ago

Both React Helmet as well as Preact itself have gone up major versions.

If you want to try it, just fork React Helmet v5 and change it to work with Preact. You can peek in the v4 version of the port to see how I dealt with some of the differences. That's how I would do it at least.

siddharthkp commented 7 years ago

@Download oh okay. Thanks, I'm going to try that.

Download commented 6 years ago

@siddharthkp

So more people are requesting this. I left you a bit dangling the previous time. Sorry about that. It would probably help a lot if you didn't have to start from scratch :)

Look here for some guidance and I'll try to help out getting you started: https://github.com/Download/preact-helmet/issues/25

siddharthkp commented 6 years ago

No worries, https://github.com/Download/preact-helmet/issues/25 is super useful