Opera dev工具报告JQuery 1.8.0(最小脚本)错误:“未处理的DOMException:SYNTAX

编程入门 行业动态 更新时间:2024-10-14 02:19:39
Opera dev工具报告JQuery 1.8.0(最小脚本)错误:“未处理的DOMException:SYNTAX_ERR”(Opera dev tools reporting JQuery 1.8.0 (min script) error: “Unhandled DOMException: SYNTAX_ERR”)

我在Opera 12的dragonfly开发工具的网页上间歇性地看到了这个错误“Unhandled DOMException:SYNTAX_ERR”。 它来自页面加载时缩小的JQuery脚本(下面的链接有更详细的信息)。 只有JQuery 1.8.0版本才会发生。 同时发布我下载的副本以及GoogleApis托管版本。 Opera论坛表示这是一个JQuery错误,因为它也发生在Chrome开发人员工具中,而在JQuery论坛上它已经关闭,因为它不是问题

我通过上面的帖子和其他一些文章阅读,但是想知道在加载此错误的时候是否对我的页面有任何功能影响。?。? 似乎不是这样,但我不能肯定地说,我也想知道是否有任何快速修复我可以应用以防止它(与配置浏览器开发工具显示/隐藏这些实例无关)?

我问第一个问题,因为要遵循两个不同的代码路径,似乎行为可能会改变,具体取决于您是否使用该功能。 免责声明:我没有通过Jquery脚本阅读,但上面的论坛说它是导致DOMException的这一行,我不知道那是什么。

try { matches.call( div, "[test!='']:sizzle" ); <---------- This line rbuggyMatches.push( Expr.match.PSEUDO ); } catch ( e ) {}

有任何想法吗?

I'm seeing this error "Unhandled DOMException: SYNTAX_ERR" intermittently on my webpage in Opera 12's dragonfly dev tool. Its coming from the minified JQuery script upon page load (the links below have more detailed info). Only happens with the JQuery 1.8.0 release. Happens with both my downloaded copy and also with the GoogleApis hosted version too. The Opera forum says it's a JQuery bug since it's happening in Chrome developer tools too and on the JQuery forum it was closed as not an issue.

I read thru the above posts and some others, but was wondering if there's any functional impact to my page on the times when it does load with this error.?.? Doesn't seem like it, but I can't say for sure and I'm also wondering if there's any quick fixes I can apply to prevent it (not related to configuring the browser dev tools from showing/hiding these instances)?

I ask the first question because with two different code paths to follow, seems like the behavior might change depending on if you're using that functionality or not. Disclaimer: I have not read thru that Jquery script, but the forums above say it's this line causing the DOMException and I have no idea what's that for.

try { matches.call( div, "[test!='']:sizzle" ); <---------- This line rbuggyMatches.push( Expr.match.PSEUDO ); } catch ( e ) {}

Any ideas?

最满意答案

看起来这只是开发人员工具的错误因为jQuery的跟踪器中的最后一条评论说:

默认情况下,12.50不再停止处理异常。

刚刚查看了jQuery 1.8.1 / Opera 12.50(build 1583)。 Opera 12.50不会停止此错误。 你可以自己检查一下。

Looks like this was a bug of developer tools only As the last comment in jQuery's tracker says:

12.50 does not stop on handled exception by default anymore.

Just checked on jQuery 1.8.1 / Opera 12.50 (build 1583). Opera 12.50 does not stop on this error. You can check it yourself.

更多推荐

本文发布于:2023-08-06 21:02:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1455787.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:脚本   最小   错误   工具   报告

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!