Closed pzi closed 2 years ago
If all it needs is to list more exports in https://github.com/Sitecore/jss/blob/dev/packages/sitecore-jss-nextjs/src/index.ts, then I can PR it if everyone's ok with it?
@pzi Yep, that should be all it takes. We would gladly welcome a PR :)
@pzi Yep, that should be all it takes. We would gladly welcome a PR :)
Done :)
Is your feature request related to a problem? Please describe.
The following types are not available from the nextjs package (not re-exported):
import type {ComponentConsumerProps} from '@sitecore-jss/sitecore-jss-react/types/enhancers/withSitecoreContext';
import type {ImageFieldValue} from '@sitecore-jss/sitecore-jss-react/types/components/Image';
import type {ImageProps} from '@sitecore-jss/sitecore-jss-react/types/components/Image';
import type {ImageSizeParameters} from '@sitecore-jss/sitecore-jss-react/types/components/Image';
import type {PlaceholderComponentProps} from '@sitecore-jss/sitecore-jss-react/types/components/Placeholder';
Describe the solution you'd like
Be able to import all these types from
@sitecore-jss/sitecore-jss-nextjs
.Describe alternatives you've considered
Augment
@sitecore-jss/sitecore-jss-nextjs
to include those, or keep importing them from within@sitecore-jss/sitecore-jss-react/types
Additional information
Is there a specific reason why these types are not exposed in the nextjs pkg? It seems inconsistent as some related types are exported (e.g.
LinkFieldValue
), so maybe they were missed?