Is it posiable to use exported variable in class in the same file its exported

Tags: ,



Is it possible to use the exported variable in class in the same file its exported?

exports.var = "something";

class c {
  constructor() {
    this.var = var;
  }
}
export.class = class;

Answer

Yes. this.var = exports.var; answer by Patrick Hund



Source: stackoverflow