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

Add overwrite property #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nordsimon
Copy link

Hello

We are working on an isomorphic react app and i liked the way this package worked. However we have some metatags only used for specific pages, it felt a bit weird to duplicate those on all other pages just to make them disappear. It will also be a place for future bugs

This PR adds an overwrite property on the component. If it is set, all previous added meta tags will be removed when calling this block again. This way you will get a full reset and it will also align with how the server render works.

@casertap
Copy link

casertap commented Sep 2, 2018

Hey @nordsimon , thanks for sharing. This is an interesting feature.
I guess you use it by doing overwrite=true in the props passed to the MetaTags component?
I do not fully understand yet, Can you please, provide an example describing the routes to your pages and the meta tags overwrite that is happening.

Thanks a lot.

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

Successfully merging this pull request may close these issues.

2 participants