There's more...

So far, we have only changed our title in the main component (<App />), but in Chapter 4, Adding Routes to Our Application with React Router V4, we are going to be able to change our titles and meta tags in different components based on a route.

Also, in Chapter 11, Implementing Server-Side Rendering, we are going to learn how to implement server-side rendering in our application. You can also use React Helmet with server-side rendering, but you need to make some changes.

First, in your index.html (Note: this file will change to a JavaScript file in Chapter 11, Implementing Server-Side Rendering; Do not try to add this to your current index.html file) you will need to add something like this:

 return `    <head> <meta charset="utf-8"> ...

Get React Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.