javascript-engine

Full callstack for multiple frames JS on IE8

半腔热情 提交于 2019-11-30 20:06:00
I need to get a full call stack when an exception occurs in JavaScript on Internet Explorer 8. Function calls may occur between frames whose number is large. Call stack necessary to send logs to the developers. I cannot use a debugger, because the end user does not have to deal with this problem. The current solution for JavaScripts provided it can generate callstack ( http://eriwen.com/javascript/js-stack-trace/ ). It is based on arguments.callee.caller. But the caller returns zero ( undefined ) if the function was called from outside the current frame. Thus callstack obtained is incomplete.

Full callstack for multiple frames JS on IE8

我的梦境 提交于 2019-11-30 03:51:57
问题 I need to get a full call stack when an exception occurs in JavaScript on Internet Explorer 8. Function calls may occur between frames whose number is large. Call stack necessary to send logs to the developers. I cannot use a debugger, because the end user does not have to deal with this problem. The current solution for JavaScripts provided it can generate callstack (http://eriwen.com/javascript/js-stack-trace/). It is based on arguments.callee.caller. But the caller returns zero ( undefined

Javascript Engines Advantages

≡放荡痞女 提交于 2019-11-28 15:57:46
I am confused about JavaScript engines right now. I know that V8 was a big deal because it compiled JavaScript to native code. Then I started reading about Mozilla SpiderMonkey , which from what I understand is written in C and can compile JavaScript. So how is this different from V8 and if this is true, why does Firefox not do this? Finally, does Rhino literally compile the JavaScript to Java byte code so you would get all the speed advantages of Java? If not, why do people not run V8 when writing scripts on their desktops? There are various approaches to JavaScript execution, even when doing

How can I detect which javascript engine (v8 or JSC) is used at runtime in Android?

陌路散爱 提交于 2019-11-27 20:45:36
Newer versions of Android ( > 2.2) include the v8 javascript engine, while older versions only had JSC. However, according to http://blogs.nitobi.com/joe/2011/01/14/android-your-js-engine-is-not-always-v8/ , which javascript engine is used at runtime seems to depend on an environment variable present at build-time ( JS_ENGINE ), as well as the hardware specs of the device: # The default / alternative engine depends on the device class. # On devices with a lot of memory (e.g. Passion/Sholes), the # default is V8. On everything else, the only choice is JSC. My question is this: is there any way

Javascript Engines Advantages

限于喜欢 提交于 2019-11-27 09:28:19
问题 I am confused about JavaScript engines right now. I know that V8 was a big deal because it compiled JavaScript to native code. Then I started reading about Mozilla SpiderMonkey, which from what I understand is written in C and can compile JavaScript. So how is this different from V8 and if this is true, why does Firefox not do this? Finally, does Rhino literally compile the JavaScript to Java byte code so you would get all the speed advantages of Java? If not, why do people not run V8 when

PHP Headless Browser? [closed]

旧街凉风 提交于 2019-11-27 04:38:01
Is there a headless browser library for PHP? Would like something that has a JS engine built into it. FOSS preferred. Anthony Hatzopoulos PhantomJS - http://phantomjs.org/ PhantomJS is a headless WebKit with JavaScript API. It has fast and native support for various web standards: DOM handling, CSS selector, JSON, Canvas, and SVG. You can couple it with something like php-PhantomjsRunner (now deprecated) if you want or bake your own . When setup and ready to start testing with PhantomJS, pick out one of the various Testing Frameworks at your disposal. I recently also came across this tutorial

How can I detect which javascript engine (v8 or JSC) is used at runtime in Android?

假如想象 提交于 2019-11-27 04:28:07
问题 Newer versions of Android ( > 2.2) include the v8 javascript engine, while older versions only had JSC. However, according to http://blogs.nitobi.com/joe/2011/01/14/android-your-js-engine-is-not-always-v8/, which javascript engine is used at runtime seems to depend on an environment variable present at build-time ( JS_ENGINE ), as well as the hardware specs of the device: # The default / alternative engine depends on the device class. # On devices with a lot of memory (e.g. Passion/Sholes),

Do browsers parse javascript on every page load?

拈花ヽ惹草 提交于 2019-11-26 14:48:20
Do browsers (IE and Firefox) parse linked javascript files every time the page refreshes? They can cache the files, so I'm guessing they won't try to download them each time, but as each page is essentially separate, I expect them to tear down any old code and re-parse it. This is inefficient, although perfectly understandable, but I wonder if modern browsers are clever enough to avoid the parsing step within sites. I'm thinking of cases where a site uses a javascript library, like ExtJS or jQuery, etc. Jivings These are the details that I've been able to dig up. It's worth noting first that

PHP Headless Browser? [closed]

核能气质少年 提交于 2019-11-26 11:18:35
问题 Is there a headless browser library for PHP? Would like something that has a JS engine built into it. FOSS preferred. 回答1: PhantomJS - http://phantomjs.org/ PhantomJS is a headless WebKit with JavaScript API. It has fast and native support for various web standards: DOM handling, CSS selector, JSON, Canvas, and SVG. You can couple it with something like php-PhantomjsRunner (now deprecated) if you want or bake your own . When setup and ready to start testing with PhantomJS, pick out one of the

How to see the source of Built-in javascript functions? [closed]

前提是你 提交于 2019-11-26 07:43:36
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 5 years ago . e.g. alert(), Object(), String(), etc. How would I see the code behind these functions? Would I need to understand the language that an engine such as V8 is written in and read through that, or is there a simpler solution. 回答1: How would I see the code behind these functions? You