Skip to content

Instantly share code, notes, and snippets.

View mividtim's full-sized avatar
🏝️
Minting properties.

Tim Garthwaite mividtim

🏝️
Minting properties.
View GitHub Profile

Keybase proof

I hereby claim:

  • I am mividtim on github.
  • I am tgarthwaite (https://keybase.io/tgarthwaite) on keybase.
  • I have a public key ASBgMln0LQ3pA4FGnWMb_6mZaCWdYw-TSDI8JEPvVDa6rwo

To claim this, I am signing this object:

@mividtim
mividtim / Json.flow.js
Last active November 7, 2018 13:09
Flow type definition (libdef) for Json, and ToJson which drops non-serializable props
// @flow
// Flow type definition for Json (lower-case so as not to collide with JSON)
// ToJson function accepts any JS variable and sets any non-serializable
// vars or properties on objects to null
// The author has found this quite useful for logging complex objects safely
export type JsonPrimitive = null | string | number | boolean;
export type JsonObject = { [string]: Json };