#8292 closed enhancement (wontfix)
Naming all eval script in Google Chrome.
Reported by: | Soul_Master | Owned by: | Soul_Master |
---|---|---|---|
Priority: | low | Milestone: | 1.next |
Component: | misc | Version: | 1.5 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
I'm not sure that latest jQuery build support this. But I just see some document about dynamic loading script or eval. You can specify name of eval script in Google Chrome by adding its name at the end of eval text.
http://code.google.com/intl/th/chrome/devtools/docs/scripts-breakpoints.html
Change History (4)
comment:1 Changed 12 years ago by
Owner: | set to Soul_Master |
---|---|
Status: | new → pending |
comment:2 Changed 12 years ago by
Status: | pending → new |
---|
If I don't misunderstand something, when we try to use html function to replace content in some Dom element, jQuery will search for all script block/tag in html and execute script block/tag by Eval function.
As you see, Google Chrome 9 able to name the dynamic loading script by adding some comments at the end of script. For example,
//@ sourceURL=jqgrid.js
PS. You might add this enhancement to JSON parse.
comment:3 Changed 12 years ago by
Component: | unfiled → misc |
---|---|
Priority: | undecided → low |
Resolution: | → wontfix |
Status: | new → closed |
This is a functionality that:
- only developers will need while debugging
- is only useful for Chrome users
- is of limited use as the names would need to be randomly generated
So I think this is nice for Chrome users and can be monkey patched onto the methods where you are interested but isn't something that belongs into jQuery core.
comment:4 Changed 12 years ago by
For the record, this isn't only available in Chrome. See http://pmuellr.blogspot.com/2009/06/debugger-friendly.html and http://blog.getfirebug.com/2009/08/11/give-your-eval-a-name-with-sourceurl/.
I have no idea what you’re asking for. Please provide a test case demonstrating whatever it is you want.