You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Async is often an easier to use abstraction for delayed computation than callbacks.
As a result, I've been writing code like this:
constinfo=awaitnewPromise<GetInfoCallbackResult>((resolve,reject)=>{tiles.getInfo((error,info)=>{if(error){// eslint-disable-next-line no-consoleconsole.log("failed to get tiles: ",TILES_PATH," from ",process.cwd())reject(error)}else{// eslint-disable-next-line @typescript-eslint/no-non-null-assertionresolve(info!)}})})
It would be nice if that became something like tiles.agetInfo(...).
It's also useful to await the constructor making things ready:
Async is often an easier to use abstraction for delayed computation than callbacks.
As a result, I've been writing code like this:
It would be nice if that became something like
tiles.agetInfo(...)
.It's also useful to
await
the constructor making things ready:It would be neat if the part where you get a promise was something like
MBtiles.ABuildMBTiles(...)
.The text was updated successfully, but these errors were encountered: