no-deprecated-deno-api
NOTE: this rule is part of the
recommended rule set.Enable full set in
deno.json:{
"lint": {
"rules": {
"tags": ["recommended"]
}
}
}Enable full set using the Deno CLI:
deno lint --rules-tags=recommended
This rule can be explictly included to or excluded from the rules present in the current tag by adding it to the
include or exclude array in deno.json:{
"lint": {
"rules": {
"include": ["no-deprecated-deno-api"],
"exclude": ["no-deprecated-deno-api"]
}
}
}Warns the usage of the deprecated - Deno APIs.
The following APIs will be removed from the Deno.* namespace but have newer
APIs to migrate to. See the
Deno 1.x to 2.x Migration Guide
for migration instructions.
Deno.BufferDeno.CloserDeno.close()Deno.Conn.ridDeno.copy()Deno.customInspectDeno.FileDeno.fstatSync()Deno.fstat()Deno.FsWatcher.ridDeno.ftruncateSync()Deno.ftruncate()Deno.futimeSync()Deno.futime()Deno.isatty()Deno.Listener.ridDeno.ListenTlsOptions.certFileDeno.ListenTlsOptions.keyFileDeno.readAllSync()Deno.readAll()Deno.ReaderDeno.ReaderSyncDeno.readSync()Deno.read()Deno.run()Deno.seekSync()Deno.seek()Deno.serveHttp()Deno.ServerDeno.shutdownDeno.stderr.ridDeno.stdin.ridDeno.stdout.ridDeno.TlsConn.ridDeno.UnixConn.ridDeno.writeAllSync()Deno.writeAll()Deno.WriterDeno.WriterSyncDeno.writeSync()Deno.write()new Deno.FsFile()
The following APIs will be removed from the Deno.* namespace without
replacement.
Deno.resources()Deno.metrics()