node-rs icon indicating copy to clipboard operation
node-rs copied to clipboard

Introduce asynchronous methods to deno-lint

Open prantlf opened this issue 3 years ago • 0 comments

Checking the sources can take a long time. Blocking the whole JavaScript VM should be avoided. The API could be changed to support asynchronous execution and let retain the synchronous methods with the well-known Sync suffix. For example:

function lint(filepath: string, source: string, enableAllRules?: boolean): Promise<string[]>
function lintSync(filepath: string, source: string, enableAllRules?: boolean): string[]

function denolint(dirname: string, configPath: string): Promise<boolean>
function denolintSync(dirname: string, configPath: string): boolean

Would you be interested in such improvement?

prantlf avatar Sep 27 '22 20:09 prantlf