0

I am about create A/B test in optimizely that involve a change in a pseudoelement (:after :before).

What I can do to change a pseudoelement style inside optimizely (let said color).

Raúl Martín
  • 4,471
  • 3
  • 23
  • 42

1 Answers1

1

Your best bet is probably to add some variation code like follows:

/* _optimizely_evaluate=force */ /*global $*/
/* _optimizely_evaluate=safe */
$('YOUR_SELECTOR::after').css('color', '#ff0000');

Which you enter by clicking on "show code" at the bottom right corner of the editor.

Info about using the editor

Here's what that'll look like