Skip to main content
Home
Docs
Courses
Workshops
Jobs
Podcast
Sign in
Docs
Reference
ClojureScript
clojure.string
trim-newline
trim-newline
function
v1.7
clojure.string/trim-newline
Available in:
BB
CLJ
CLJS
(
trim-newline
[
s
]
)
Removes all trailing newline \n or return \r characters from string. Similar to Perl's chomp.
Examples
Sign in to contribute
Code
Platforms
Clojure
ClojureScript
Babashka
Submit
Cancel
No examples yet. Be the first to add one!
Categories
Strings › Manipulation
See Also
blank?
capitalize
ends-with?
escape
includes?
index-of
join
last-index-of
lower-case
replace
← trim
triml →
All
⌘1
Clojure
⌘2
ClojureScript
⌘3
Babashka
⌘4