REFACTOR use MetaComponents() method allowing for better extensibility #64
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
resolves #59
This is a fairly major change to how the tags are built. I've updated the existing tests to match using the
MetaComponents()
method and things appear to be generating as expected.One thing I did not take into account with this update is if there is a desire for additional logic surrounding the handling of the canonical tag for things like Virtual Page, or if a canonical already exists from some other extension. If this module's extension is loaded last, it will simply overwrite any canonical in the MetaComponents. That being said, any module using the
MetaTags()
method, and setting a canonical could result in two canonical tags being generated.Open to feedback on any/all of this and am happy to update where needed.