Created
September 13, 2019 19:52
-
-
Save evaporei/971b5ae80fe538fc96ebbfe3e20d28ae to your computer and use it in GitHub Desktop.
Category Theory - Functor Container
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
| class Container<T> { | |
| private value: T | |
| constructor(value: T) { | |
| this.value = value | |
| } | |
| } | |
| console.log('simple container:', new Container(5)) // Container { value: 5 } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment