Closed. This question does not meet Stack Overflow guidelines。它当前不接受答案。












想要改善这个问题吗?更新问题,以便将其作为on-topic用于堆栈溢出。

3年前关闭。



Improve this question




我需要向使用Angular 2构建并与Webpack捆绑在一起的大型应用程序添加A/B测试功能。

VWO之类的工具对我们来说不够灵活。

有在线指南或提示吗?

谢谢。

最佳答案

如果其他人也有同样的问题,我将推出一种产品来解决这一需求。它非常适合Angular2/4或任何其他JavaScript框架。

这是docs的示例。您可以轻松地为某个函数切换jQuery DOM操作,该函数将更新绑定(bind)到ng-if的变量以用于Angular。

var experiment = engauge.experiment({
    name: 'signup-button',
    variants: {
        // This is the first variant. It should be your control.
        '#ff5722': {
            activate: function() {
                $('#signup-col').html('<button class="variant-1 signup-button">Try it Free</button>');
            }
        },
        // This is the second variant.
        '#9c27b0': {
            activate: function() {
                $('#signup-col').html('<button class="variant-2 signup-button">Try it Free</button>');
            }
        }
    }
});

现在,主页位于https://engaugeab.com上,如果您提到这篇文章,我将为您提供扩展的免费套餐。

10-07 19:20
查看更多