6

Typescript Example #1.

 2 years ago
source link: https://dev.to/baenencalin/typescript-example-1-ia3
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client
Typescript Example #1.
// An example of generics in TypeScript.
class Option<T> {
    constructor(v:T|null=null) { this.value = v; }
    readonly value:T|null;
}
Enter fullscreen modeExit fullscreen mode

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK