Skip to content

Instantly share code, notes, and snippets.

💭
🍄🌈

Thomas Schranz tosh

Block or report user

Report or block tosh

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
@alastairs
alastairs / Cambridge Software Crafters Email.md
Last active Apr 12, 2018
Email to the Cambridge Software Crafters re: name change and CoC
View Cambridge Software Crafters Email.md

Changes to the Cambridge Software Craftsmanship Community

Hi everyone

It's not often that we email our members, so please bear with me and read this to the end.

Recent events in the wider tech community, and reactions within the Software Craftsmanship community, have prompted wider discussions about the inclusiveness of the community, and I've decided to make some small but important changes to our local chapter.

@yogthos
yogthos / gallery.cljs
Last active Jul 20, 2018
script to download walpapers from windowsonearth.org
View gallery.cljs
@reborg
reborg / rich-already-answered-that.md
Last active May 24, 2019
Clojure Design Decisions
View rich-already-answered-that.md

Rich Already Answered That!

A list of commonly asked questions, design decisions, reasons why Clojure is the way it is as they were answered directly by Rich (even when from many years ago, those answers are pretty much valid today!). Feel free to point friends and colleagues here next time they ask (again). Answers are pasted verbatim (I've made small adjustments for readibility, but never changed a sentence) from mailing lists, articles, chats.

How to use:

  • The link below in the summary jumps at the answer on this page.
  • The link on the question itself points back at the original post.

Summary

@swannodette
swannodette / inference.md
Last active Apr 11, 2019
Externs Inference
View inference.md

Externs Inference

Integrating third party JavaScript libraries not written with Google Closure Compiler in mind continues to both be a source of error for users when going to production, and significant vigilance and effort for the the broader community (CLJSJS libraries must provide up-to-date and accurate externs).

In truth writing externs is far simpler than most users imagine. You only need externs for the parts of the library you actually intend to use from ClojureScript. However this isn't so easy to determine from Closure's own documentation. Still in the process of writing your code it's easy to miss a case. In production you will see the much dreaded error that some mangled name does not exist. Fortunately it's possible to enable some compiler flags :pretty-print true :pseudo-names true to generate an advanced build with human readable names. However debugging missing externs means compiling your production build for each missed case. So much time wasted for such simple mistakes damages our sen

@mfikes
mfikes / source.md
Last active Dec 27, 2016
Source for C and ClojureScript comparison
View source.md
@fasiha
fasiha / learn_datalog_today.clj
Created May 10, 2016
Learn Datalog Today ported to DataScript & Clojure (JVM)
View learn_datalog_today.clj
; Learn Datalog Today (http://www.learndatalogtoday.org) is a great resource for
; reading but its interactive query interface is broken. Below is how we can
; load the same data into a Clojure REPL and play with it using DataScript.
; After running the code below, many/most/all? of the queries on Learn Datalog
; Today should be functional.
;
; Create a new lein project, add `[datascript "0.15.0"]` to `project.clj`'s
; `dependencies`, run `lein deps && lein repl` and copy-paste the following in
; chunks, inspecting the outputs as needed.
@jasongilman
jasongilman / atom_clojure_setup.md
Last active May 9, 2019
This describes how I setup Atom for Clojure Development.
View atom_clojure_setup.md

Atom Clojure Setup

This describes how I setup Atom for an ideal Clojure development workflow. This fixes indentation on newlines, handles parentheses, etc. The keybinding settings for enter (in keymap.cson) are important to get proper newlines with indentation at the right level. There are other helpers in init.coffee and keymap.cson that are useful for cutting, copying, pasting, deleting, and indenting Lisp expressions.

Install Atom

Download Atom

The Atom documentation is excellent. It's highly worth reading the flight manual.

@paul356
paul356 / clojure-ctags.md
Last active Aug 27, 2017 — forked from vladh/clojure-ctags.md
Add Clojure support to exuberant ctags and vim-tagbar
View clojure-ctags.md

ctags

Add the following to ~/.ctags (thanks, xzj / clojure.ctags):

--langdef=Clojure
--langmap=Clojure:.clj
--langmap=Clojure:+.cljs
--langmap=Clojure:+.cljx
--regex-clojure=/\([ \t]*create-ns[ \t]+([-[:alnum:]*+!_:\/.?]+)/\1/n,namespace/
--regex-clojure=/\([ \t]*def[ \t]+([-[:alnum:]*+!_:\/.?]+)/\1/d,definition/
@vladh
vladh / clojure-ctags.md
Last active Dec 15, 2018
Add Clojure support to exuberant ctags and vim-tagbar
View clojure-ctags.md

ctags

Add the following to ~/.ctags (thanks, xzj / clojure.ctags):

--langdef=Clojure
--langmap=Clojure:.clj
--regex-clojure=/\([ \t]*create-ns[ \t]+([-[:alnum:]*+!_:\/.?]+)/\1/n,namespace/
--regex-clojure=/\([ \t]*def[ \t]+([-[:alnum:]*+!_:\/.?]+)/\1/d,definition/
--regex-clojure=/\([ \t]*defn[ \t]+([-[:alnum:]*+!_:\/.?]+)/\1/f,function/
--regex-clojure=/\([ \t]*defn-[ \t]+([-[:alnum:]*+!_:\/.?]+)/\1/p,private function/
@vsavkin
vsavkin / transducers.dart
Last active Dec 15, 2015
Transducers in Dart
View transducers.dart
library transducers;
import 'dart:async';
reduce(coll, Function fn, init) {
// Reduce function for Iterable.
if (coll is Iterable) {
var result = init;
final iterator = coll.iterator;
while (iterator.moveNext()) {
You can’t perform that action at this time.