Questions tagged [ecmascript-5]

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 5th Edition is an update of the 3rd edition specification after the cancellation of the 4th edition. It adds new features including strict mode, getters and setters, a JSON object, and new methods for Object, Array, Date, and Function prototypes.

In 1995 Brendan Eich of Netscape invented a scripting language JavaScript for the Netscape browser. One year later Microsoft developed a compatible dialect of the language, JScript. Lately flash platform implemented its ActionScript language based in the same standard.

Netscape delivered JavaScript to Ecma International for standardization which started the process as EcmaScript in the Ecma-262 Standard in November 1996(5).

ECMAScript-5 is an update of the EMCAScript-262 3rd edition specification after the cancellation of the 4th edition. It adds new features including strict mode, getters and setters, a JSON object, and new methods for Object, Array, Date, and Function prototypes.

Articles covering the new specification in detail are available e.g. on infoq.com and the Opera Dev Channel.

This compatibility table covers the Browser support of EcmaScript 5.

References:

  1. JavaScript Wikipedia Article
  2. EcmaScript Wikipedia Article
  3. Ecma International Website
  4. Ecma-262 Specification
  5. Press Release of Javascript Standardization
  6. EcmaScipt Edition 5 - HTML Version
  7. EcmaScript Edition 3 - PDF Version
1857 questions
0
votes
1 answer

Typescript - generics in function property does not get resolved

i'm pretty new to typescript and i'm trying to play with nested generics. By now I can't make them work as i would expect, probably i'm missing something obvious. Here is my sample code: type GenericServiceResponse = { status: number; …
0
votes
3 answers

Building dynamic json using javascript/angularjs

I am building a dynamic json with the data coming from the server using angularjs. I have declared it as below. it only works if data from server has one item in the object array. How should i declare for it to work dynamically? $scope.items =…
sai123
  • 105
  • 12
0
votes
1 answer

Global variables to different files and classes

I've a bigger object where I save all important data of my main class. My project is getting kinda bigger so I've some seperated files/classes. All of them need to have access to my store object, which values gonna change from time to time. I know I…
bonblow
  • 1,151
  • 6
  • 19
  • 28
0
votes
1 answer

not executing all the cases in switch statement

i have an array of objects i need to append the 0 index object to a div and 1 index object to another div. Using switch case returns from the initial case itself not executing the second index let arr =…
Learner
  • 8,379
  • 7
  • 44
  • 82
0
votes
2 answers

How to make ESLint ignore class names and methods from other files?

This has probably been asked before, but I don't really know how to search for it so if it has, I am really sorry. Say I have a file called a.js that has a class called Navigation in it, then in b.js I call that with a method inside the class called…
ChronixPsyc
  • 478
  • 1
  • 8
  • 22
0
votes
0 answers

Flow and Object.getOwnPropertyNames

I'm having issues typing my code with flow. What I want to achieve is a recursive function that deep freezes and object. I have the following implementation: const isObject: (any => boolean) = object => ( object !== null && typeof object ===…
gerrit
  • 391
  • 3
  • 11
0
votes
1 answer

How to load a Polymer element on IE11 that works also on evergreen browsers?

To load a Polymer element in IE11, we should compile it to es5 syntax, and to use the same file in Chrome we need custom-elements-es5-adapter.js. custom-elements-es5-adapter.js cannot be used on IE11 as it is supposed to be in es6 syntax. Its kind…
Sanjeev
  • 855
  • 1
  • 9
  • 15
0
votes
2 answers

JS closure to return object instance as interface

I have the following code. function Test() { this.funct_1 = function() { alert('funct_1'); } this.funct_2 = function() { alert('funct_2'); } return this;} function getTestObj() { var testObj; if (!testObj) { testObj = new…
vzhemevko
  • 815
  • 8
  • 25
0
votes
0 answers

Include Same third party library in multiple html files using ES5

I want to use many third party JS libraries in my application. Application is built using ES5. Currently the application contains 14 html files. All files show different content but same third part JS library is required by all HTML files. Is there…
user6754
  • 71
  • 1
  • 8
0
votes
0 answers

How to get single element from a for loop? Vanilla JavaScript ES5

I'm trying to make a 'Scroll Spy' feature in Vanilla JavaScript ES5. Get the depth scrolled. Get each section depth with offsetTop. If the scrolled <= THE section give me the section So if section 1 give me section 1 If it's past the section 2…
0
votes
1 answer

How to prevent BabelJS from making global variable of 'arguments' keyword?

In a project I have this BabelJS configuration: { "presets": ["es2016"] } And somewhere in the code there is a method using the standard JS 'arguments' keyword to deal with a dynamic range of parameters. Something like this: const myFunction = ()…
Jos
  • 419
  • 3
  • 12
0
votes
0 answers

Pushing object to Array makes parameter empty

I'm trying to solve problem of merging two arrays of objects, so I wrote a pretty simple function function mergeShowtimes(movies) { var existing_halls = []; return movies.reduce(function(acc, movie) { var movies_with_hallid, …
Nausik
  • 735
  • 8
  • 22
0
votes
1 answer

Node.JS Callback Scoping Issues

I'm using JavaScript classes to write a small tool for work. I don't like callbacks nesting and nesting, so I like to break them out into separate functions. I'm trying to run requests, which take a callback, from within a for...of loop. The problem…
user4158347
0
votes
0 answers

GMAIL List Like Style, Select, Drop and Append - JavaScript ES5

I'm doing something like GMAIL in JS ES5, I'm just using const and let, that's it. The purpose: User click on the red rectangle and can move it to any list. When the user has overmouse the heading3, the heading3 changes bg color and the mouse will…
0
votes
0 answers

Moving items to different lists with DOM Manipulation JS

I'm creating something like GMAIL functionality with JavaScript ES5 ( I use only const and let, that's it, rest ES5). So I manage to create the list functionality, all works except that when I select the items and move them to a different list,…
1 2 3
99
100