Current status of ES6 "class" implementation.

Talk about code development, features, specific bugs, enhancements, patches, and similar things.
Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific bugs, git, the repositories, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Please post issues with specific websites, extensions, etc. in the relevant boards for those topics.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
BenFenner
Astronaut
Astronaut
Posts: 588
Joined: 2015-06-01, 12:52
Location: US Southeast

Current status of ES6 "class" implementation.

Unread post by BenFenner » 2017-12-05, 14:33

As the sole champion of Pale Moon at my web development shop, it has fallen on me to make this thread.

We just spent some time debugging odd JS behavior on one of our sites (they are very light on JS as a general rule) which only Pale Moon exhibits (tested working in Opera, FF, IE, Chromium, Chrome, Safari, and Edge). We narrowed it down to the seeming lack of support for the ES6 `class` keyword in Pale Moon.
I found this thread on the topic: viewtopic.php?f=13&t=14589&hilit=es6+class

I would have bumped that thread from January 2017, but it is locked. With all due respect, it seems to be 11 months since the last mention of this on the forum and the locked thread leaves tons of unanswered questions about the future of this feature. I'm not entirely sure what to expect with this as PM progresses. Is support not planned, ever? Or are we as forum members just not allowed to discuss it? Or what?

Either way, I'd like to see what the current state of things are in this area. We may have a work-around for our specific issue now, but I'd like to keep myself informed about the state of this feature in Pale Moon (hence this thread).
I realize support for this may be very difficult. I'm just wondering if there is a vague plan to eventually support this? Or a solid plan to eventually support this? Or is support ever to be expected? With this information, I can make better educated plans for our shop's future. Thank you.
Last edited by BenFenner on 2017-12-05, 15:13, edited 1 time in total.

BenFenner
Astronaut
Astronaut
Posts: 588
Joined: 2015-06-01, 12:52
Location: US Southeast

Re: Current status of ES6 "class" implementation.

Unread post by BenFenner » 2017-12-05, 14:38

I'm reading how divisive "class" is in JavaScript: https://medium.com/javascript-scene/how ... 42bb3f4caf

To be clear, our shop is not trying to use "class" in JavaScript. We are merely making use of a 3rd party plug-in that relies on it. We may find alternatives. JavaScript we write ourselves is not the problem.
I may go make a bug report for this 3rd party plug-in.
Last edited by BenFenner on 2017-12-05, 14:57, edited 1 time in total.

BenFenner
Astronaut
Astronaut
Posts: 588
Joined: 2015-06-01, 12:52
Location: US Southeast

Re: Current status of ES6 "class" implementation.

Unread post by BenFenner » 2017-12-05, 14:52

I've submitted a report to the 3rd party plug-in: https://github.com/peek/peek-performance_bar/issues/30

User avatar
Sajadi
Board Warrior
Board Warrior
Posts: 1226
Joined: 2013-04-19, 00:46

Re: Current status of ES6 "class" implementation.

Unread post by Sajadi » 2017-12-05, 15:44

On Github this special one is marked with a bounty sign. Means, it waits for someone to implement it who has time and that special knowledge which is required for implementation.

if you have perhaps an idea of a person who could do it, feel free to forward them towards the specific Github post :)

https://github.com/MoonchildProductions ... ssues/1243

BenFenner
Astronaut
Astronaut
Posts: 588
Joined: 2015-06-01, 12:52
Location: US Southeast

Re: Current status of ES6 "class" implementation.

Unread post by BenFenner » 2017-12-05, 16:10

Sajadi, thanks for the explanation and link. That's exactly what I needed. If I find anyone who can tackle the issue, I will pass it on. :thumbup:

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35474
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Current status of ES6 "class" implementation.

Unread post by Moonchild » 2017-12-06, 10:12

As regards locked threads: all threads on this forum are automatically locked after a specific period of inactivity (more than half a year since the last activity) to prevent necro-posting on long-closed and concluded discussion topics that has been an constant issue lately. Don't take this kind of lock as a dismissal of the topic.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35474
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Current status of ES6 "class" implementation.

Unread post by Moonchild » 2018-03-07, 09:34

An update to this thread.

I've done some more work on getting the dependencies in (e.g. "super") but the more I see about how this all hooks together, the more ES6 classes are plainly a BAD IDEA, especially how it is all specced.
With classes you're going to generate a very fragile dependency chain that works in a way completely a-typical to the way JavaScript normally works. I really don't think the little bit of convenience it creates for people wanting to do C++ abstraction comes anywhere near being proportional to the cost for the language as a whole.
Classes in JS are simply a really, really bad idea, trying to enforce OO structures from a different language to something that is simply not designed to do things that way.

There's also no reason to use classes per se, as anything done with classes can be done with basic and completely compatible use of JS prototypes. Prototyping is there for a reason; use it.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

BenFenner
Astronaut
Astronaut
Posts: 588
Joined: 2015-06-01, 12:52
Location: US Southeast

Re: Current status of ES6 "class" implementation.

Unread post by BenFenner » 2018-03-08, 15:55

Interesting reading. Thanks for the update! :thumbup:

Locked