Add reviews props#8
Conversation
Include moment.js package
| render(): Element<any> { | ||
| const { title, loadingBehavior = LoadingBehaviors.ShowLoader, isLoading } = this.props; | ||
|
|
||
| if (loadingBehavior == LoadingBehaviors.ShowLoader && isLoading) { |
There was a problem hiding this comment.
I noticed related products component stoped using loading behaviour https://github.com/FoxComm/storefront.react.js/blob/master/src/components/related-products-list/related-products-list.jsx#L67
maybe we should do the same for reviews?
There was a problem hiding this comment.
Yes, change this to be
if (isLoading) {
return <WaitAnimation />;
}
| @@ -0,0 +1,2 @@ | |||
|
|
|||
| export default from './action-link'; | |||
There was a problem hiding this comment.
Not sure why you added index but still uses
import ActionLink from 'components/core/action-link/action-link';
instead of
import ActionLink from 'components/core/action-link';
There was a problem hiding this comment.
Thanks, I forgot to update that
| {this.props.shareImage} | ||
| </div> | ||
| {this.props.relatedProductsList} | ||
| {this.props.reviewsList} |
There was a problem hiding this comment.
Any reason why you removed these changes? It's about to inject reviews on pdp page.
|
@taywils I also think we should add line inside export ProductReviewsList from './components/product-reviews-list/product-reviews-list'; |
| render(): Element<any> { | ||
| const { title, loadingBehavior = LoadingBehaviors.ShowLoader, isLoading } = this.props; | ||
|
|
||
| if (loadingBehavior == LoadingBehaviors.ShowLoader && isLoading) { |
There was a problem hiding this comment.
Yes, change this to be
if (isLoading) {
return <WaitAnimation />;
}
|
|
||
| type Props = { | ||
| isLoading: ?boolean, | ||
| loadingBehavior?: 0|1, |
| page: number, | ||
| } | ||
|
|
||
| export const LoadingBehaviors = { |
There was a problem hiding this comment.
These LoadingBehaviors will need to be removed
|
@taywils I've just pushed an update, could you please have a look again. I am trying it on demo peacock. |

No description provided.