Skip to content

Instantly share code, notes, and snippets.

@akihisa-shimada
Last active December 17, 2021 00:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save akihisa-shimada/ed241580b2f441b91e98f5d9bfe472f1 to your computer and use it in GitHub Desktop.
Save akihisa-shimada/ed241580b2f441b91e98f5d9bfe472f1 to your computer and use it in GitHub Desktop.
function identity<T>(arg: T): T {
return arg;
}
console.log(identity<string>("string"));
console.log(identity(1));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment