123
rated 0 times
[
125]
[
2]
/ answers: 1 / hits: 111143
/ 7 Years ago, fri, september 22, 2017, 12:00:00
Why is this example below not outputting hello world? Instead, I am getting:
TypeError: _base2.default.test is not a function
(it is being transpiled with Babel)
file1.js
import Example from './file2';
console.log(Example.test());
file2.js
export default class Example {
test() {
console.log('hello world');
}
}
More From » import