Questions tagged [ecmascript-3]

ECMAScript is the name of the Ecma International Standard 262. It is based on the scripting language JavaScript which was delivered by Netscape to Ecma for standardization. The 3rd Edition was published in 1999 following the 2nd edition of the specification which was published in 1998. It adds new features including regular expressions, numeric formatting, and try/catch exception handling.

ECMAScript is the name of the Ecma International Standard 262. It is based on the scripting language JavaScript which was delivered by Netscape to Ecma for standardization.

The 3rd Edition was published in December 1999 following the 2nd edition of the specification which was published in June 1998. It adds new features including regular expressions, numeric formatting, and try/catch exception handling.

38 questions
6
votes
2 answers

Why variable object was changed to lexical environment in ES5?

ES5 changed variable object(VO) to lexical environment. What's the motivation of such change since VO is already very obvious as perception?
Thomson
  • 20,586
  • 28
  • 90
  • 134
5
votes
2 answers

Target different Javascript versions with TypeScript

TypeScript can globally target different versions of Javascript - you can switch between transpiling ES3, ES5 or ES6. We have to support IE, so ES3 is our lowest common denominator. However, good browsers (like Chrome) already support ES6, and will…
Keith
  • 150,284
  • 78
  • 298
  • 434
3
votes
1 answer

How do I pass an object to Adobe ExtendScript from Javascript (Adobe CEP)?

I'm working with Adobe CEP (it lets developers create windowed extensions for Adobe CC products). The bulk of my code is modern JavaScript (the platform uses Chromium 57, Node.js 7.7.4). However, in order to access the DOM, I need to write some…
Jason Weinzierl
  • 342
  • 1
  • 6
  • 12
2
votes
2 answers

How were "classes" extended prior to class syntax and Object.create?

I have not been able to find an answer to this. Objects in JavaScript have an inheritance chain; the chain of any function is Function => Object, the chain of an instance of TypeError is TypeError => Error => Object, and the chain of TypeError is,…
2
votes
0 answers

Return an object method with the object context on JS (ES3)

I have this code: function Selector(){ this.name = 'Selector'; this.select = function(fName){ return this[fName] } this.funcOne = function(arg){ console.log(arg + this.name) } } var mySelector = new…
Miguel
  • 709
  • 7
  • 21
2
votes
0 answers

Does JScript (ES3, in ScriptControl ActiveX object within VBA) support creation of non-enumerable parameters?

If I define a property/function into an Object prototype (assuming that coercion will eventually lead to every variable accessing the property/function) as such ... Object.prototype.doFunc = function(){ return 'this is ' + this;} // OUTPUT -…
2
votes
2 answers

How to get all Unicode characters from specific categories?

How to get, for example..., a code point pattern like x-y\uxxxx\Uxxxxxxxxx from the Connector Punctuation (Pc) category, for scanning ECMAScript 3/JavaScript identifiers? Original question I need help for verifying a valid character (code point) of…
user5066707
2
votes
1 answer

Constant pattern in Javascript

How were implemened constants in javascript before ES5 was released? There were no get/set stuff, no writable property, no const word, no Object.freeze stuff as far as I know, so how I could make my own constant, which can't be changed? Like, as…
DanilGholtsman
  • 2,354
  • 4
  • 38
  • 69
2
votes
3 answers

Should arguments.slice() work in ES5?

I'm watching Crockford on Javascript - Act III: Function the Ultimate at around 41 mins 26 seconds. The code on his screen uses arguments.slice() in a way that causes an error for me. function curry(func){ var args = arguments.slice(1); …
brentonstrine
  • 21,694
  • 25
  • 74
  • 120
2
votes
1 answer

Do RegExps made by expression literals share a single instance?

The following snippet of code (from Crockford's Javascript: The Good Parts) demonstrates that RegExp objects made by regular expression literals share a single instance: function make_a_matcher( ) { return /a/gi; } var x = make_a_matcher(…
George
  • 6,927
  • 4
  • 34
  • 67
1
vote
2 answers

How to figure out what Javascript methods/features/etc are available in ECMAscript 3.0

Hey I have an interesting question, I work with a platform that uses server-side javascript, but unfortunately this platform only supports ECMAscript 3.0. What's the easiest way for me to tell what arrays/methods are available for me to use within…
balwill
  • 119
  • 1
1
vote
1 answer

Group and filter items from an array

I have an array called items, here is a sampel of the data inside the array: [ { "id":"123", "key":"xxx111@gmail.com", "status":"attempted" }, { "id":"123", "key":"xxx111@gmail.com", "status":"waiting" …
RedWitch
  • 123
  • 2
  • 13
1
vote
0 answers

Getting a reference to the global object in an weird and rare es3-based environment

First things first: target/host env is quite rare and weird at same time, so I am OK if this ends with nothing. Pls excuse me in advance for time you might spent on it. A plot: my friend and I come up with a "plugin" (JS code) for some win32 app to…
ZuBB
  • 124
  • 2
  • 8
1
vote
0 answers

JavaScript Array Operations in the MS Script Control

This is a JavaScript question, but... my objective is to use the Microsoft Script Control in Excel VBA to carry out array operations. The script control uses MS JScript, roughly equal to ES3, but having no window object. When I say…
Excel Hero
  • 14,253
  • 4
  • 33
  • 40
1
vote
1 answer

How to run/test ECMAScript 3 JavaScript code?

I am working on ExtendScript and it currently supports ECMAScript 3. Is there a way I can run or test some snippets in ECMAScript 3 version engine? I mean how can I check that the code I wrote is supported by ECMAScript 3?
Ishan Patel
  • 5,571
  • 12
  • 47
  • 68
1
2 3