Skip to content

Release v2.0.0

Choose a tag to compare

@michaloo michaloo released this 15 Jun 11:10
· 20 commits to master since this release
0b7b4c5
  • BREAKING HullClient is a set of ES6 classes now, not a Function anymore - this means you cannot do const hullClient = HullClient() anymore, you always need new keyword
  • BREAKING as method is not available anymore, use asUser
  • BREAKING utils.groupTraits method is not available anymore, use utils.traits.group
  • BREAKING traits method second parameter accepting source and sync option is not available anymore. Sync calls are not available at all, and if you need to apply source to your traits you need to do it before passing payload to traits method
  • BREAKING hullClient.api.get methods are not available anymore, use hullClient.get or hullClient.api(path, "get"), the same applies for all HTTP verbs
  • the client now comes with full set of Flow types in src/types.js file
    import type { HullUserClaims } from "hull-client";
    
    const userClaims: HullUserClaims = {
      wrong_claim: "bar"
    };
    // this will throw flow check error since `wrong_claim` is not correct
  • underlying HTTP library restler was replaced with superagent