Functions

core

Built-in. No import needed.

plus minus times over modarithmetic
eq neq lt gt lte gtecomparison
and or notlogical

math

math abs xabsolute value
math min x yminimum
math max x ymaximum
math floor xround down
math ceil xround up
math round xround nearest
math sqrt xsquare root
math pow x ypower
math log xnatural log
math sin xsine
math cos xcosine
math random0 to 1

str

str len slength
str concat a bjoin
str split s sepsplit
str trim swhitespace
str upper suppercase
str lower slowercase
str contains s subhas substring
str replace s old newreplace all
str slice s start endsubstring

list

list len llength
list get l iat index
list set l i vset index
list push l vappend
list pop lremove last
list first lfirst element
list last llast element
list slice l start endsublist
list reverse lreverse
list sort lsort
list map l fntransform
list filter l fnkeep matching
list reduce l fn initfold

time

time nowunix ms
time dateISO string
time parse sparse string
time format t fmtformat
time year tget year
time month tget month
time day tget day

err

err new msgcreate error
err msg eget message
err is xcheck if error
err wrap e msgadd context

http

http get urlGET
http post url bodyPOST
http put url bodyPUT
http delete urlDELETE

json

json parse sparse string
json string xto JSON
json get x pathget field
json set x path vset field
json has x pathfield exists