Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Why Clojure?. Parent comment
As a general first rule, make the alias the same as the namespace name with the leading parts removed.
(ns com.example.application (:require [clojure.java.io :as io] [clojure.string :as string]))
[clojure.data.xml :as data.xml] [clojure.xml :as xml]
[clj-http :as http] [clj-time.core :as time] [clj-time.format :as time.format]
Namely:
(require '[dk.ative.docjure.spreadsheet :as spreadsheet])
About `d`:
There are always exceptions. For example, some namespaces have established conventions for aliases:
[datomic.api :as d]
There are no comments on this comment yet.
As a general first rule, make the alias the same as the namespace name with the leading parts removed.
Keep enough trailing parts to make each alias unique. Did you know that namespace aliases can have dots in them? Eliminate redundant words such as “core” and “clj” in aliases. Then you can see immediately what `d` is...Namely:
(You would still not know the library and might have to ask the same question, but it makes more sense.)About `d`:
There are always exceptions. For example, some namespaces have established conventions for aliases: