class Foo { constructor () { this.initialize(); } async initialize () { const res = await randomMethod(); const res2 = await randomMethod2(); } } const bar = new Foo();
await this.initialize();
Join the Discord to ask follow-up questions and connect with the community
The best chat community for professionals using React or React Native
75,391 Members