Skip to content

Instantly share code, notes, and snippets.

View Pilatch's full-sized avatar
🐢

Ethan B Martin Pilatch

🐢
View GitHub Profile
@cscalfani
cscalfani / elmInNode.md
Last active April 6, 2020 20:57
Elm in Node (0.17)

Elm in Node (0.17)

Why?

Sharing code between the client and the server in a Universal Javascript application is a big gain. No more are the days of rewriting code for the server.

But moving from Javascript to Elm in the front end can feel like a move backwards. So much of the code we write is environment independent. And it would be great if we could leverage some of the front end logic on the backend.

How?

@mkremins
mkremins / pbcopy.js
Created April 17, 2014 21:41
node.js: put text into OS X clipboard
function pbcopy(data) {
var proc = require('child_process').spawn('pbcopy');
proc.stdin.write(data);
proc.stdin.end();
}