Releases: tizmagik/react-head
v3.4.2
v3.4.0 - Base head tag now exported
We now also export base
head tag, thanks to @gjacobrobertson in #105
v3.3.0
v3.1.1
v3.1.0
v3.0.2 - Fixes for IE
v3.0.1
v3.0.0
Many thanks to @TrySound for this release! 🎉
If you're migrating from v2.x
, the TL;DR for what you need to change is:
- Rename
<HeadCollector />
to<HeadProvider />
(provide aheadTags[]
prop on the server) <HeadProvider />
is now also required on the client (it does not need aheadTags[]
prop)
You can view a diff example of exactly what's required to upgrade from the example app upgrade here: 00ccda7
New Features
- Cascading now supported for
<Title />
and<Meta />
- CJS, UMD and ESM bundles now provided
Bug Fixes
- Open Graph protocol now supported
- Certain characters in head tags broke client hydration; all content should work fine now.
Breaking Changes
<HeadProvider />
(formerly<HeadCollector />
) now required on both server and client<HeadTag />
is removed from public api in favour of aliases (Title
,Meta
,Style
,Link
)- React 16.3+ now required (react-head now uses the new Context API)
Changelog
35b249f Update Example for v3 API (#60)
7989654 Mention HeadProvider requirement in client (#59)
4f8a383 Support open graph protocol (#58)
14c44aa Remove prop-types (#56)
6d6fc02 Remove all SSR tags on mount (#55)
996c2e1 Fix rendering style and link on client (#53)
af98110 Make HeadProvider mandatory in the tree (#52)
a67506c (tag: v3.0.0-1) 3.0.0-1
5ad1a4f Update size snapshot
7add5b2 Make headTags in optional for client (#50)
e3b77e4 Remove HeadTag in favor of head tag components (#47)
1d3f522 Upgrade babel to rc1 (#48)
c9ace2e Update README.md
27f7710 Update Example to follow v3 API (#42)
6d14c74 Add support for cascading meta (#39)
ead3722 Add support for cascading titles (#37)
d48ca47 Upgrade types according api (#38)
752a9ea Replace enzyme with react-test-renderer (#36)
3ab9902 Rename HeadCollector to HeadProvider (#35)
v2.2.0 - Smaller build, CJS + ESM via Rollup
Many thanks to @TrySound for a lot of the recent updates 🎉
0e5d9f7 Remove prop-types in production (#28)
f9a47d1 Enable babel loose mode to reduce library size (#27)
b763e32 Add babel runtime to reuse helpers across packages (#25)
5569b79 Upgrade to babel 7 (#24)
16825f9 Bundle cjs and esm with rollup (#22)
v2.1.0 - Convenience HeadTag aliases now available
Thanks to @TrySound in #20 we now also export some common aliases for use:
import React from 'react';
import { Title, Style, Meta, Link } from 'react-head';
const App = () => (
<div className="Home">
<Title>Title of page</Title>
<Link rel="canonical" content="http://jeremygayed.com/" />
<Meta tag="meta" name="example" content="whatever" />
// ...
</div>
)