What's the best way to bind ES6 class's "this" to an arrow function?
<p>I want to separate class methods into their own files. For example if I have a simple class like this in <code>test.js</code>:</p>

<pre><code>export default class TestClass {

    testFunction(...args) {
        return require('./test-function').apply(this, args);
    }

}
</code></pre>

<p>And then in <code>test-function.js</code> method:</p>

<pre><code>export default function() {
    /* `this` keyword works fine */
}
</code></pre>

<p>However, if I change it to an arrow function, then <strong>this</strong> does not work anymore (because of lexical scoping?):</p>

<pre><code>export default () =&gt; {
    /* `this` doesn't work anymore */
}
</code></pre>

<p>How would I bind <code>this</code> properly so my arrow <code>test</code> function can use it?</p>