We've just added class support to RunKit! JavaScript classes are shorthand that make it easier to work with JavaScript's existing protoypal inheritance. As usual, RunKit is smart about the way it supports this feature, using Babel in earlier versions (like 0.12), but giving you full access to native classes in Node 4 and 5, even when not in strict mode. Give it a try:
class AbstractMockSingletonFactoryFactory
{
injectDependency()
{
console.log("Subclasser Responsibility");
}
}
This brings RunKit's ES6 support to near completion, making it one of the best places to try the latest JavaScript features in every version of Node!
- Classes (native support 4+)
- Symbols (native support 0.12+)
- Generators (native support 0.12+)
- Template Strings (native support 4+)
- Spread and Rest parameters (native support 5+)
- Arrow Functions (native support 4+)
- Destructuring
- Enhanced object literals
- Default parameters in functions
- Map + Set + WeakMap + WeakSet (0.12+)
- Promises
- Binary and octal literals
- Async functions
- JSX
Don't forget, we're holding office hours on Thursday if you want to stop by and discuss this or any other JavaScript features.
What is RunKit?
- RunKit is an interactive playground for running Node.js in the cloud.
- RunKit offers serverless functions with zero deploy time — prototype code changes in real time!
- RunKit can be embedded in your tutorials and docs to make them interactive as seen on lodash.com, expressjs.com, and stripe.com.
Follow RunKit Blog updates with the RSS Feed
Follow @runkitdev on Twitter for the latest updates from RunKit
© 2015–2018 Playground Theory, Inc.
Follow @runkitdev on Twitter for the latest updates from RunKit
© 2015–2018 Playground Theory, Inc.