Consider the following module:
export class Bar {
generateFoo() {
return new Foo(1);
}
}
class Foo {
constructor(fooValue) {
this.fooValue = fooValue;
}
doFoo() { console.log(this.fooValue); }
}
Should I export Foo
too in any situation? Why/Why not?
Aucun commentaire:
Enregistrer un commentaire