Skip to content

Instantly share code, notes, and snippets.

Dan Minshew newswim

Block or report user

Report or block newswim

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
chexxor /
Last active Jun 8, 2019
PureScript Lazy-load Modules Idea

Lazy/Dynamic Loadable Modules in PureScript



  • Here, we aren't first-class modules, because we are still using the normal module definition and import system. We believe that first-class modules refer to a special feature in OCaml.
  • Can not refer to type classes across a lazy-load boundary. Type-class instances and classes are not first-class values.
Kazark / NotNotLEM.idr
Last active Nov 13, 2018
Intuitionist logic is by no means denying the law of excluded middle!
View NotNotLEM.idr
module NotNotLEM
%default total
%access public export
notDistributesOverEither : Not (Either a b) -> (Not a, Not b)
notDistributesOverEither neither = (notLeft neither, notRight neither) where
notLeft : Not (Either a b) -> Not a
notLeft neither x = neither (Left x)
busypeoples / HashTrie.js
Last active Jul 16, 2018
Implementing persistent data structures with HashTries
View HashTrie.js
// @flow
// Immutable Data Implementation
// Based on Hash Tries
// (NOTE: The actual implementation is based on hashed mapped tries!)
// But this can be seen as a basis for the actual implementation.
// This is only for learning purposes!
// Hash Trie or Hash Tree is a persistent data structure, commonly used
// to implement immuable maps.

I bundled these up into groups and wrote some thoughts about why I ask them!

If these helped you, I'd love to hear about it!! I'm on twitter @vcarl_ or send me an email

Onboarding and the workplace

  • How long will it take to deploy my first change? To become productive? To understand the codebase?
  • What kind of equipment will I be provided? Will the company pay/reimburse me if I want something specific?
View 16.3-blogpost-signatures.js
class Example extends React.Component<
> {
static getDerivedStateFromProps(
nextProps: Props,
prevState: State
): $Shape<State> | null {
// ...

Super Preliminary Elm - Web Assembly Research

Back in December 2017, I started working on something I called Elmish-Wasm, which was just an experimental repo to compile something Elm-like to Wasm. I made some progress, but the helpful people I talked and I came to the conclusion that most of what I had so far (Haskell and Regex to interpret .elm files into rudimentary wasm) was something the Elm compiler and the Elm AST already did. Writing that code was a lot of fun, but maybe not the most valuable way to explore Elm and WebAssembly. Before jumping back into this project I would like to record the important facts and questions related to compiling Elm to Wasm.

What is Wasm?

A lot of people talk about Web Assembly as if its C++ that runs in the browser. Thats not the case. This belief must come from that fact that C can currently compile to web assembly. Wasm is human-unreadable bytecode. There is a human-readable version of wasm, called wat. It looks like this..

;; A function that adds two numbe
bvaughn / eager-prefetching-async-data-example.js
Last active May 12, 2019
Advanced example for eagerly prefetching async data in a React component.
View eager-prefetching-async-data-example.js
// This is an advanced example! It is not intended for use in application code.
// Libraries like Relay may make use of this technique to save some time on low-end mobile devices.
// Most components should just initiate async requests in componentDidMount.
class ExampleComponent extends React.Component {
_hasUnmounted = false;
state = {
externalData: null,
r00k / gist:2f243be6c30325f6a9b31844d91fc910
Last active Dec 14, 2017
uBlock Origin filters to remove annoying Twitter features
View gist:2f243be6c30325f6a9b31844d91fc910
gmaclennan /
Last active Jul 4, 2018
Long-distance solar-powered wifi in the forests and savannahs of Guyana


Digital Democracy is looking for a volunteer to help pilot long-distance solar-powered wifi antennaes in indigenous communities in Guyana.


Digital Democracy is working with the Wapichan people in the South Rupununi in Guyana to support them in efforts to secure their ancestral territory and increase their autonomy and self-determination. The Wapichan live in 17 villages and 7 smaller "satellites" in a large semi-natural savannah ecosystem surrounded by tropical forest. Communication between villages and with the outside world is difficult due to limited or no cellphone or internet access. We want to help the Wapichan improve their means of communicating with the rest of the world and communicating and coordinating between villages.


You can’t perform that action at this time.