jss
jss copied to clipboard
[sitecore-jss-nextjs] Placeholder applies the modifyComponentProps prop.
- [x] This PR follows the Contribution Guide
- [x] Changelog updated
Description / Motivation
The Placeholder component in the "nextjs package" does not apply the modifyComponentProps
when given. Instead, the component adds its own implementation of modifyComponentProps
that it provides to the Placeholder component from the "react package". The component needs to also apply the modifyComponentProps
property as well.
Testing Details
- [ ] Unit Test Added
- [x] Manual Test/Other (Please elaborate)
I tried to add a unit test but I lack knowledge of how Enzyme works. When I attempt to call mount
on the Placeholder component it fails with the message Cannot read properties of null (reading 'useContext')
. All other tests seem to have no problems though.
So far I tested this solution by modifying the module files inside the node_modules folder of my particular project.
Types of changes
- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
@Adamduehansen Thank you for submitting your contribution! I've added a ticket containing all the details, which has been added to our internal backlog for thorough review