Skip to content

Commit 7b2c93d

Browse files
committed
qualify those names in clojure.string
1 parent 96768bb commit 7b2c93d

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -490,11 +490,13 @@ pairwise constructs as found in e.g. `let` and `cond`.
490490
* Leverage `comp` when it would yield simpler code.
491491

492492
```Clojure
493+
;; Assuming `(:require [clojure.string :as str])`...
494+
493495
;; good
494-
(map #(capitalize (trim %)) ["top " " test "])
496+
(map #(str/capitalize (str/trim %)) ["top " " test "])
495497

496498
;; better
497-
(map (comp capitalize trim) ["top " " test "])
499+
(map (comp str/capitalize str/trim) ["top " " test "])
498500
```
499501

500502
* Leverage `partial` when it would yield simpler code.

0 commit comments

Comments
 (0)