Dimitrian Nine (2019-08-26T15:11:37.000Z)
dimtimeforever at gmail.com (2019-08-26T15:17:52.566Z)
Ok so much time has passed. I have learned more js. And created some [wrapper][1] for my idea: Class is just function constructor that return object. Async Class is async function constructor that returns promise object. Wrapper code: ```js class PromiseClass { //promisified class static async new(obj){ return obj;} constructor() {return PromiseClass.new(this); }//new }//class class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass static async new(obj){return await obj();} constructor(){return AsyncClass.new(async()=>{await super(); return this});}//new }//AsyncClass ``` And we work with Async Class like we work with functions. I dont see here some differents to use them. Code without wrapper be clean: ```js async class PromiseClass { //return Promise constructor() {}//async()=>Promise object }//class async class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass constructor(){ await super();} //async()=>Promise object }//AsyncClass ``` [1]:https://repl.it/repls/UnsightlyStylishLogic
dimtimeforever at gmail.com (2019-08-26T15:17:01.210Z)
Ok so much time has passed. I have learned more js. And created some [wrapper][1] for my idea: Class is just function constructor that return object. Async Class is async function constructor that returns promise object. Wrapper code: ```js class PromiseClass { //promisified class static async new(obj){ return obj;} constructor() {return PromiseClass.new(this); }//new }//class class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass static async new(obj){return await obj();} constructor(){return AsyncClass.new(async()=>{await super(); return this});}//new }//AsyncClass ``` And we work with Async Class like we work with functions. I dont see here some differents to use them. Code without wrapper be clean: ```js async class PromiseClass { //return Promise constructor() {}//async()=>Promise object }//class async class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass constructor(){ await super();} //async()=>Promise object }//AsyncClass ``` [1]:https://repl.it/repls/UnsightlyStylishLogic
dimtimeforever at gmail.com (2019-08-26T15:16:45.033Z)
Ok so much time has passed. I have learned more js. And created some [wrapper][1] for my idea: Class is just function constructor that return object Async Class is async function constructor that returns promise object. Wrapper code: ```js class PromiseClass { //promisified class static async new(obj){ return obj;} constructor() {return PromiseClass.new(this); }//new }//class class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass static async new(obj){return await obj();} constructor(){return AsyncClass.new(async()=>{await super(); return this});}//new }//AsyncClass ``` And we work with Async Class like we work with functions. I dont see here some differents to use them. Code without wrapper be clean: ```js async class PromiseClass { //return Promise constructor() {}//async()=>Promise object }//class async class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass constructor(){ await super();} //async()=>Promise object }//AsyncClass ``` [1]:https://repl.it/repls/UnsightlyStylishLogic
dimtimeforever at gmail.com (2019-08-26T15:14:52.035Z)
Ok so much time has passed. I have learned more js. And created some [wrapper][1] for my idea: Class is just function constructor that return object Async Class is async function constructor that returns promise object. Wrapper code: ```js class PromiseClass { //promisified class static async new(obj){ return obj;} constructor() {return PromiseClass.new(this); }//new }//class class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass static async new(obj){return await obj();} constructor(){return AsyncClass.new(async()=>{await super(); return this});}//new }//AsyncClass ``` And we work with Async Class like we work with functions. I dont see here some differents to use them. Code without wrapper be clean: ```js async class PromiseClass { //return Promise constructor() {}//async()=>Promise object }//class async class AsyncClass extends PromiseClass{ // can ext Class|PromiseClass constructor(){ await super();} //async()=>Promise object }//AsyncClass ``` [1]:https://repl.it/repls/UnsightlyStylishLogic