Last active
July 31, 2018 11:19
-
-
Save tswistak/40c4aac2e66312bf7c7bbfec36c72598 to your computer and use it in GitHub Desktop.
TypeScript 3.0, listing 4
This file contains hidden or 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
| // JavaScript | |
| function jsHello() { | |
| return [...arguments].join(','); | |
| } | |
| // JavaScript, second way | |
| function jsHello1(...args) { | |
| return args.join(','); | |
| } | |
| // TypeScript | |
| function tsHello(...args: any[]): string { | |
| return args.join(','); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment