Skip to content

Instantly share code, notes, and snippets.

@iwikal
iwikal / mod.ts
Created September 25, 2021 16:16
option.ts
import noneInstance from './none'
import SomeClass from './some'
function createSome<T>(value: T) {
return new SomeClass(value)
}
export type Some<T> = SomeClass<T>
export const Some = createSome

Keybase proof

I hereby claim:

  • I am iwikal on github.
  • I am iwikal (https://keybase.io/iwikal) on keybase.
  • I have a public key ASArVILfo_G5ZlvT37hKqUttzM1h_822qbApTIOQhlkmmgo

To claim this, I am signing this object: