question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ES6 classes for commands

See original GitHub issue

Hi, is it possible to use es6 classes for commands?

modules.exports = class CustomCommand() {
    command() {
   }
}

At the moment I got such error: Class constructor CreateHubCommand cannot be invoked without ‘new’

Any plans to support this?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:10 (2 by maintainers)

github_iconTop GitHub Comments

19reactions
aaronbeallcommented, Mar 24, 2017

@beatfactor Just curious, is there any roadmap or update on when an ES6 class API might be available? I’d like to know because it would mean we could use TypeScript (ES6 classes + static typing). We can use TS now but the the compiler has a hard time following our code because of the behind-the-scenes magic that Nightwatch does. Cheers.

7reactions
sandeepthukralcommented, Jun 28, 2017

Any update?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using Classes - ECMAScript 6 Tutorial
ECMAScript 6 introduces the concept of class available in traditional object-oriented languages. In ECMAScript 6, the class syntax is syntactical sugar on top ......
Read more >
class - JavaScript - MDN Web Docs - Mozilla
The class body of a class declaration is executed in strict mode. The constructor method is optional. Class declarations behave like let and ......
Read more >
Javascript Classes - ES6-with-Real-World-Applications - GitHub
JavaScript classes, introduced in ES6 (ECMAScript 2015), are primarily syntactical sugar over JavaScript's existing prototype-based inheritance.
Read more >
Classes & Methods in JavaScript with ES6 - JS OOPS #1
letcode # javascript #protractorSorry for the long video guys, In this video, we'll learn Class & Methods - OOPS concept in javascript.
Read more >
Coding Train Live 102: Intro to ES6 Classes - YouTube
In this live stream, I tackle the subject of ES6 classes and Object Oriented Programming in JavaScript. I also do a short coding...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found