This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function decorate(target: any) {} | |
@decorate | |
class Foo {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Deno.utime(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export enum DocNodeKind { | |
Function = "function", | |
Variable = "variable", | |
Class = "class", | |
Enum = "enum", | |
Interface = "interface", | |
TypeAlias = "typeAlias", | |
Namespace = "namespace", | |
} | |
export interface DocNodeLocation { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function example(param?: string) { | |
return "test"; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function greeter(name?: string) { | |
console.log("Hello" + (name ? " " + name : "") + "!"); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const test = "hello"; | |
export { test }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license. | |
/// <reference no-default-lib="true" /> | |
/// <reference lib="esnext" /> | |
export namespace Deno { | |
/** The current process id of the runtime. */ | |
export let pid: number; | |
/** Reflects the NO_COLOR environment variable. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const proc = Deno.run({ | |
cmd: ["deno", "doc", "lib.deno.d.ts", "--json", "--reload"], | |
stdout: "piped", | |
stderr: "piped" | |
}); | |
const status = await proc.status(); | |
await Deno.copy(Deno.stdout, proc.stdout) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import * as voca from "voca"; | |
console.log(voca); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Compile file:///home/lucacasonato/Downloads/test.ts | |
error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. | |
► file:///home/lucacasonato/Downloads/test2.ts:5:7 | |
5 hello(1); |