(post?: Post)
| 30 | * layout, so the post page and the post modal stay in sync. |
| 31 | */ |
| 32 | export const usePostRedesign = (post?: Post): UsePostRedesign => { |
| 33 | const isEligible = isPostRedesignEligible(post); |
| 34 | const { value: isFlagOn } = useConditionalFeature({ |
| 35 | feature: featurePostRedesign, |
| 36 | shouldEvaluate: isEligible, |
| 37 | }); |
| 38 | |
| 39 | return { isEligible, showRedesign: isEligible && isFlagOn }; |
| 40 | }; |
no test coverage detected