Skip to content

Instantly share code, notes, and snippets.

View joyrexus's full-sized avatar

J. Voigt joyrexus

View GitHub Profile
@joyrexus
joyrexus / README.md
Last active August 29, 2015 14:07
concurrent programming design
@joyrexus
joyrexus / README.md
Last active August 29, 2015 14:07
behavioral datasets
@joyrexus
joyrexus / README.md
Last active August 29, 2015 14:07
3 maxims, 5 rules

The following 3 maxims are attributed to Tony Hoare, Ken Thompson, and Fred Brooks, respectively. The 5 rules (distributed under the maxims) are attributed to Rob Pike.


Premature optimization is the root of all evil

You can't tell where a program is going to spend its time. Bottlenecks occur in surprising places, so don't try to second guess and put in a speed hack until you've proven that's where the bottleneck is.

Measure. Don't tune for speed until you've measured, and even then don't unless one part of the code overwhelms the rest.

@joyrexus
joyrexus / README.md
Last active August 29, 2015 14:07 — forked from max-mapper/index.js
Prototype vs object style

Prototype style

function Person(first, last) {
    this.first = first;
    this.last = last;
}

Person.prototype.greet = function () {
@joyrexus
joyrexus / README.md
Last active November 11, 2020 00:29
html form design resources

HTML Forms

  • fundamentals - best pratices for creating forms and user input
  • bootstrap - css for boostrap-styled form elements
  • form builder - drag-and-drop bootstrap form elements to build a form
  • forms - node module for programmtically creating, parsing and validating forms
@joyrexus
joyrexus / README.md
Last active August 29, 2015 14:06
sample validation script
@joyrexus
joyrexus / README.md
Last active July 18, 2025 03:13 — forked from tristanwietsma/auth.go
golang web examples
@joyrexus
joyrexus / README.md
Last active August 29, 2015 14:06
Decks from markdown

Resources for generating slide decks from markdown.

  • swipe - a simple deck service
  • remark - provides inline markdown rendering
  • medium - fork of big.js with on-the-fly markdown parsing
  • big.artemis.cat - generates a deck from a gist
@joyrexus
joyrexus / README.md
Last active September 1, 2023 02:46
File upload POST with curl

Extracted from this excellent curl tutorial


Back in late 1995 they defined an additional way to post data over HTTP. It is documented in the RFC 1867, why this method sometimes is referred to as RFC1867-posting.

This method is mainly designed to better support file uploads. A form that allows a user to upload a file could be written like this in HTML:

@joyrexus
joyrexus / README.md
Last active September 7, 2024 14:28
Form/file uploads with hapi.js

Demo of multipart form/file uploading with hapi.js.

Usage

npm install
npm run setup
npm run server

Then ...