In foo.js
class Foo {
    run(){
        console.log("test");
    }
}
In index.js
'use strict'    
var test = require('./foo.js'),
    Test = new test();
Test.run();
How to export the Foo class in iojs 3?
I tryed this way and worked, but i dont know if this is the right way:
module.exports = class Foo {
                    run(){
                        console.log("test");
                    }
                 }
				
                        
In current io.js you can do something like this to get your class exported so it can be imported with require():
and