启用JavaScript时,Azure B2C中的自定义模板在IE11中不起作用 [英] Custom Template in Azure B2C doesn't work in IE11 when JavaScript is enabled

查看:79
本文介绍了启用JavaScript时,Azure B2C中的自定义模板在IE11中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Azure Active Directory B2C中具有SignIn V2策略 我还启用了JavaScript 因为我用它来操纵表单中的某些元素.

I have a SignIn V2 policy in Azure Active Directory B2C I also enabled JavaScript Because I use it to manipulate some elements in the form.

此配置在Google Chrome浏览器中效果很好,但是每当我尝试在Internet Explorer 11中运行它时,都会得到

This configuration works well in Google Chrome, but whenever I try to run it in Internet Explorer 11, I get

SCRIPT1002:语法错误

SCRIPT1002: Syntax error

在控制台中,并且登录按钮没有响应.

In the console, and the login button doesn't respond.

启用JavaScript时会发生这种情况. 当我禁用它时,该页面可以在IE11中运行(但是我的操作却不起作用).

This happens when JavaScript is enabled. When I disable it, the page works in IE11 (But my manipulations don't).

以前有人遇到过这个问题吗?

Has anyone encountered this problem before?

推荐答案

我发现了问题所在. 我使用的是ES6语法,例如

I found out what the problem was. I was using ES6 syntax such as

() => {
  ...
}

一旦我将其替换为

function () {
  ...
}

它适用于IE11.

谢谢 @托马斯 和 @Zhi Lv-MSFT

Thank you @Thomas and @Zhi Lv - MSFT

这篇关于启用JavaScript时,Azure B2C中的自定义模板在IE11中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆