mirror of
https://github.com/vercel/commerce.git
synced 2025-05-15 14:06:59 +00:00
Removed suspense
This commit is contained in:
parent
cc2fb3543e
commit
4721cdf365
@ -17,8 +17,6 @@ interface getContentComponentProps {
|
|||||||
const getContentComponent = ({ _type, _key, disabled, ...rest }: getContentComponentProps) => {
|
const getContentComponent = ({ _type, _key, disabled, ...rest }: getContentComponentProps) => {
|
||||||
let Component: any;
|
let Component: any;
|
||||||
|
|
||||||
console.log(_key);
|
|
||||||
|
|
||||||
switch (_type) {
|
switch (_type) {
|
||||||
case 'hero':
|
case 'hero':
|
||||||
Component = Hero;
|
Component = Hero;
|
||||||
@ -67,9 +65,9 @@ const getContentComponent = ({ _type, _key, disabled, ...rest }: getContentCompo
|
|||||||
}
|
}
|
||||||
|
|
||||||
return Component ? (
|
return Component ? (
|
||||||
<Component key={`index-${_key}`} {...rest} />
|
<Component key={`${_key}`} {...rest} />
|
||||||
) : (
|
) : (
|
||||||
<div key={`index-${_key}`}>Something else</div>
|
<div key={`${_key}`}>Something else</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user