VOOZH about

URL: https://thenewstack.io/all-about-e-the-language-that-infiltrated-javascript/

⇱ All About E: The Language that Infiltrated JavaScript - The New Stack


TNS
SUBSCRIBE
Join our community of software engineering leaders and aspirational developers. Always stay in-the-know by getting the most important news and exclusive content delivered fresh to your inbox to learn more about at-scale software development.
REQUIRED
It seems that you've previously unsubscribed from our newsletter in the past. Click the button below to open the re-subscribe form in a new tab. When you're done, simply close that tab and continue with this form to complete your subscription.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.
Welcome and thank you for joining The New Stack community!
Please answer a few simple questions to help us deliver the news and resources you are interested in.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Great to meet you!
Tell us a bit about your job so we can cover the topics you find most relevant.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Welcome!

We’re so glad you’re here. You can expect all the best TNS content to arrive Monday through Friday to keep you on top of the news and at the top of your game.

What’s next?

Check your inbox for a confirmation email where you can adjust your preferences and even join additional groups.

Follow TNS on your favorite social media networks.

Become a TNS follower on LinkedIn.

Check out the latest featured and trending stories while you wait for your first TNS newsletter.

PREV
1 of 2
NEXT
VOXPOP
As a JavaScript developer, what non-React tools do you use most often?
Angular
0%
Astro
0%
Svelte
0%
Vue.js
0%
Other
0%
I only use React
0%
I don't use JavaScript
0%
Thanks for your opinion! Subscribe below to get the final results, published exclusively in our TNS Update newsletter:
NEW! Try Stackie AI
From clobbered drafts to real-time sync
Apr 14th 2026 10:00am, by David Moore
TypeScript 6.0 RC arrives as a bridge to a faster future
Mar 14th 2026 9:00am, by Darryl K. Taft
Mastra empowers web devs to build AI agents in TypeScript
Jan 28th 2026 11:00am, by Loraine Lawson
2022-10-21 09:03:11
All About E: The Language that Infiltrated JavaScript
Frontend Development / Open Source / Software Development

All About E: The Language that Infiltrated JavaScript

JavaScript owes part of its development to a retired open source language with a small community, called E.
Oct 21st, 2022 9:03am by Loraine Lawson
👁 Featued image for: All About E: The Language that Infiltrated JavaScript
Feature image via Shutterstock

Doug Crockford is best known for his long-time work in JavaScript and for creating the JSON Data Interchange Format. His opinion tends to carry weight — and Crockford said it’s time to retire JavaScript.

“JavaScript, like the other dinosaur languages, has become a barrier to progress,” Crockford told IT outsourcing firm Evrone in an interview. “We should be focused on the next language, which should look more like E than like JavaScript.”

What is E? Wikipedia calls E “an object-oriented language for securing distributed computing,” and by design, E emphasizes security. But to learn more about E’s impact on JavaScript, The New Stack spoke with Mark Miller, the main designer of E, which he co-created with Dean Tribble as well as several Electric Communications colleagues, including Crockford, Doug Barnes, Dan Bornstein, and Chip Morningstar during the mid-1990s.

“Both Doug and I had a lot to do with the birth of the language,” Miller told us. “We were quite in love with the language that we had created.”

Miller considers the language itself dead — an open source language, E never attracted more than 100 users to the community, he said.

But E didn’t go softly into that good night — its influence is still seen in JavaScript today, thanks to the efforts of Miller, Crockford, and other members of the ECMAScript standards committee. Miller explained to The New Stack how E influenced JavaScript, how his company Agoric still puts the E ideas to use in DeFi with blockchain, and the additional aspects of E he’d like to see upcycled into JavaScript.

12 Angry Men and ECMAScript

“Have you seen the movie 12 Angry Men?” Miller asked me. I have, I replied. “I think that movie is the best way to explain what the ECMAScript committee was like at the time that I joined Google.”

Crockford convinced Miller to join the committee in 2007 as an additional Google representative. The committee was focused on upgrading ECMAScript 3 to ECMAScript 4 but it wasn’t going well.

“The committee had been meeting continuously from 1999 to 2007 at this point, and they still did not have a successor standard. Most of the committee was focused on ECMAScript 4, which in my opinion was a horrible language,” Miller said. “Doug started off as the one holdout — the Henry Fonda character saying, ‘No, we will not agree on this.’”

JavaScript was messy, complicated and weird, but Crockford convinced Miller that ECMAScript 3 had the seeds for an E-like experience and that it had the core enabling elements that would allow it to become an E-like secure distributed programming language.

“I joined his revolt against ECMAScript 4, and that revolt had several other members by that time — just like in 12 Angry Men — he incrementally convinced the jurors to come over to his camp,” Miller said. Eventually, the revolt won. The successor to ECMAScript 3 became ECMAScript 5, the version designed by the revolters while the rest of the committee focused on ECMAScript 4.

“The ECMAScript 5 standard did have the enablers for using JavaScript as a straightforward, simple, secure programming language. We were both very proud of what we did for ECMAScript 5,” he said.

One fundamental aspect of E they brought over in ECMAScript 5 was support for the object-capability security model, he said.

“JavaScript’s functions together with JavaScript’s objects, used as records, can be combined to create a pattern that Doug named the objects-as-closures pattern, and if you use JavaScript as objects-as-closures, the expressiveness feels much like E. But as of ECMAScript 3, it doesn’t have the security yet.”

The enablers they got into ECMAScript 5 enabled them to write the SES-shim, a library that brings about a secure language state, which is now called Hardened JavaScript, Miller said.

Freeze

In ECMAScript 5, they introduced several enablers, the primary being Object.freeze(). Despite its name, it has nothing to do with immutability, Miller said. Instead, it tamper-proofs the surface of an object so that the clients of the object can now only interact with the object — according to the object’s explicit behavior, Miller explained. The provider of the object can populate it with methods that capture internal state variables and can encapsulate that state, so the clients of the object cannot tamper with it. By “freezing,” what’s meant is that the properties of the object can no longer be changed, he added.

“The client can no longer change the shape of the object. So the shape of the object is fixed. The internal state is now hidden from the clients,” he said. “Now the object becomes something that can only be interacted with according to the object’s design.”

That step addressed a security problem: prototype poisoning, in which objects created in traditional JavaScript were all mutable and can be subverted to confuse or surveil other parts of a program by anyone who had access to them.

“One of the things that we do with freeze and with the other enablers that we got into ECMAScript 5 (Object.getOwnPropertyNames() and Object.getPrototypeOf() ) is we were able to write something we call ‘harden(),’ which is a transitive freeze that walks an object graph, freezing all of the objects that it finds by doing property traversal. We were able to enumerate all of the primordial objects, all of the objects that JavaScript programs within the same environment implicitly share, like Array and Array.prototype, etc.,” Miller said.

I/O Expression

The SES-shim library, at the beginning, when it initializes, does some repairs on the primordials, then hardens all of the primordials, he said. That ensures all of the implicitly shared objects are now genuinely immutable.

“We did some repair on the committee so that the primordials didn’t have any hidden mutable state or hidden I/O abilities,” he said.

Everything that was implicitly shared is completely powerless and immutable, he added, so that sharing does not violate isolation.

Another crucial enabler was the ability to virtualize all I/O. One of the beautiful and under-appreciated aspects of JavaScript, Miller said, is that the language is about computation — not about I/O. JavaScript programs express I/O by performing a global variable lookup of a host-provided object, like “document” in the browser or “process” in Node.

Those host-provided global variables are not standardized as part of the language standard, but are brought in by the host that provides all of the I/O abilities for affecting the outside world or for sensing the outside world.

“What that means is that if you can intervene in the global scope lookup, you can completely virtualize all of the I/O and that’s what we made possible with our enablers in ECMAScript 5. Hardened JavaScript continues to use the enablers to intercept the global scope lookup,” he said.

Hardened JavaScript is what Agoric still uses today. Agoric writes most of their code within a disciplined subset of Hardened JavaScript called Jessie (a name intended to evoke a combination of JS and E). Jessie emphasizes Crockford’s objects-as-closures pattern as an alternative to JavaScript’s inheritance mechanisms.

Promises

Another important aspect of E ported to JavaScript is non-blocking promises, which E was the first language to have, Miller said. Promises happened in ECMAScript 6 and those promises are directly based on E promises.

“A promise is an object returned by an asynchronous function. … the promise object provides methods to handle the eventual success or failure of the operation,” explains MDN web docs. E in a Walnut explains promises in more detail. Essentially, in promise systems before E, the calling thread would at some point block, waiting for the operation to complete. In much the way one wouldn’t wait for someone to finish a task on a project before beginning to work on one’s own tasks, E’s non-blocking promises made it possible to handle the eventual success or failure of the operation without blocking to wait for the resolution.

JavaScript’s promises only provide for local asynchrony out of the box, but Agoric’s Endo libraries extend them to also provide E-like distributed object-capability security over cryptographic protocols, making JavaScript into an E-like distributed secure language.

ECMAScript 6 introduced E’s non-blocking promises. But ECMAScript 6 also introduced classes and became at least twice as big … and kept growing, Miller said. It became more complex, an anathema to both Miller and Crockford. While Miller stayed, Crockford left the committee, essentially seeing JavaScript as a lost cause, according to Miller.

Miller still sees potential in JavaScript.

”I do not see it as a lost cause,” he told The New Stack. “I’m very proud of what we’ve continued to accomplish in the efforts of the committee, enabling us to use it as an E-like distributed secure language.”

TRENDING STORIES
Loraine Lawson is a veteran technology reporter who has covered technology issues from data integration to security for 25 years. Before joining The New Stack, she served as the editor of the banking technology site Bank Automation News. She has...
Read more from Loraine Lawson
SHARE THIS STORY
TRENDING STORIES
SHARE THIS STORY
TRENDING STORIES
TNS DAILY NEWSLETTER Receive a free roundup of the most recent TNS articles in your inbox each day.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.