Sha256: 5e7c653674344587b462f59eccb7a21fff841d95d0b2057fde922b64711be5b1

Contents?: true

Size: 1.39 KB

Versions: 6

Compression:

Stored size: 1.39 KB

Contents

require! [
  './Func.js'
  './List.js'
  './Obj.js'
  './Str.js'
  './Num.js'
]

id = (x) -> x

is-type = (type, x) --> typeof! x is type

replicate = (n, x) -->
  [x for til n]


Str <<< List{
  empty, slice, take, drop, split-at, take-while, drop-while, span, break-str: break-list
}

prelude = {
  Func, List, Obj, Str, Num,
  id, is-type
  replicate,
}
prelude <<< List{
  each, map, filter, compact, reject, partition, find,
  head, first, tail, last, initial, empty,
  reverse, difference, intersection, union, count-by, group-by,
  fold, foldl, fold1, foldl1, foldr, foldr1, unfoldr, and-list, or-list,
  any, all, unique, sort, sort-with, sort-by, sum, product, mean, average,
  concat, concat-map, flatten,
  maximum, minimum, scan, scanl, scan1, scanl1, scanr, scanr1,
  slice, take, drop, split-at, take-while, drop-while, span, break-list,
  zip, zip-with, zip-all, zip-all-with,
}
prelude <<< Func{
  apply, curry, flip, fix,
}
prelude <<< Str{
  split, join, lines, unlines, words, unwords, chars, unchars
}
# not importing all of Obj's functions
prelude <<< Obj{
  values, keys,
  pairs-to-obj, obj-to-pairs, lists-to-obj, obj-to-lists,
}
prelude <<< Num{
  max, min, negate, abs, signum, quot, rem, div, mod, recip,
  pi, tau, exp, sqrt, ln, pow, sin, tan, cos, acos, asin, atan, atan2,
  truncate, round, ceiling, floor, is-it-NaN, even, odd, gcd, lcm,
}

prelude.VERSION = '1.0.3'

module.exports = prelude

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
conjur-asset-ui-1.3.2 vendor/prelude-ls/src/index.ls
conjur-asset-ui-1.3.1 vendor/prelude-ls/src/index.ls
conjur-asset-ui-1.3.0 vendor/prelude-ls/src/index.ls
conjur-asset-ui-api-1.2.0 vendor/prelude-ls/src/index.ls
conjur-asset-ui-api-1.1.1 vendor/prelude-ls/src/index.ls
conjur-asset-ui-api-1.1.0 vendor/prelude-ls/src/index.ls