nuxt-community / google-optimize-module

SSR friendly Google Optimize module for Nuxt.js
MIT License
215 stars 32 forks source link

Support for several experiments #37

Closed swiftyjam closed 4 years ago

swiftyjam commented 4 years ago

Hello! I have been testing the module and looks like it works fine, but I dont know how would I be able to use two experiments at the same time. So I'm looking for something like this:

`<div v-if="$experiments[$exp.name] === 'background'" class="absolute w-12 h-12 z-50 m-auto top-0 pt-16 right-0 bg-red-300 left-0"

experimento background activo

<div v-if="$exp.name === 'text'" class="absolute w-12 h-12 z-50 m-auto top-0 pt-16 right-0 bg-red-300 left-0"

experimento texto activo

`

hecktarzuli commented 4 years ago

Users only get assigned 1 experiment at a time. This protects your test data to make sure the results don't dilute each other.

pi0 commented 4 years ago

Hi @gambasconjamon indeed as @hecktarzuli mentioned, we cannot mix experiments because they affect each other. However it is possible to assign multiple varients of a same experiment (it is called multivariate test or MVT) for this you need to put sections with a number higher than 1 (docs)