Skip to content

2.0.0

Latest
Compare
Choose a tag to compare
@thibmaek thibmaek released this 23 May 11:25
· 5 commits to master since this release

What's Changed

Breaking changes

  • Data modules are now lowercased:
-import { Arrays } from 'pure-fun';
+import { arrays } from 'pure-fun';
  • arrays/head will now act like initial did: it returns everything but the last item in an array
  • arrays/initial will now act like head did: it returns the first element
  • arrays/getDuplicates was renamed to arrays/duplicates
  • async/simpleFetch was renamed to async/fetchJSON
  • objects/isObject would previously also pass on functions and classes. It now only validates if your data is a plain object literal
  • objects/makeIterable was removed since it does not work with microbundle/bublé at the moment
  • objects/parseJSON will now return the passed input if it is a valid JS object and not JSON where it would previously return {}

New functions

  • async/isPromise: Check if your data is an async type/promise
  • functions/isFunction: Check if your data is a valid callable function
  • isomorphics/isIterable: Check if your data is an iterable instance
  • maps/isMap: Check if your data is a Map
  • sets/isSet: Check if your data is a Set
  • strings/isString: Check if your data is a valid string