Skip to content

Ab test rammeverk#440

Draft
thomaslund wants to merge 10 commits intomasterfrom
ab-testing
Draft

Ab test rammeverk#440
thomaslund wants to merge 10 commits intomasterfrom
ab-testing

Conversation

@thomaslund
Copy link
Contributor

No description provided.

const { Provider } = ExperimentsContext;
const useVariant = experiments.find(
experiment =>
experiment.id.localeCompare(experimentId, undefined, {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hvorfor bruke localeCompare? Og hvorfor ikke bruke isValidExperiment funksjonen fra under?

experiments: ExperimentShape[];
}

export const fetchVariantIndex = ({
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kan ikke se at denne blir brukt noe sted? Viss den blir det bør den i en util funksjon

experimentId,
onVariantMount,
}}>
{children}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bedre API og sende inn en array med varianter i stedet for renderprops? Trenger man ikke eksponere til ndla-frontend, og man trenger ikke context for man kan bare sende props direkte inn.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Takk for gode tilbakemeldinger. Vi ser på saken 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants