Skip to content

Commit

Permalink
update hook deps and docs (#15208)
Browse files Browse the repository at this point in the history
  • Loading branch information
erikdstock authored Feb 14, 2025
1 parent 3378d66 commit 4501add
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion docs/unleash_a-b_testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,10 @@ function MyComponent() {
})


// biome-ignore lint/correctness/useExhaustiveDependencies: Only track experiment viewed once
useEffect(() => {
trackFeatureVariant()
})
}, [])

return (
// Your Components
Expand Down
3 changes: 2 additions & 1 deletion src/Components/ArtsyShippingEstimate.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,10 @@ export const ArtsyShippingEstimate = (props: ArtsyShippingEstimateProps) => {
variantName: variant?.name ?? "control",
})

// biome-ignore lint/correctness/useExhaustiveDependencies: Only track experiment viewed once
useEffect(() => {
trackFeatureVariant()
})
}, [])

if (variant?.name === "experiment") {
return <ArtsyShippingEstimateLoader {...props} />
Expand Down

0 comments on commit 4501add

Please sign in to comment.