Skip to content
This repository has been archived by the owner on Sep 25, 2023. It is now read-only.

Releases: webcarrot/api

v2.0.0

30 Sep 14:03
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v1.8.0...v2.0.0

Permission to optionally stop the request

04 Mar 12:55
Compare
Choose a tag to compare

React example:

const Component = ({id}: {id:string}) => {
      const api = React.useContext(ApiContext);
      const [obj, setObj] = React.useState<SomeType>(null);
      React.useEffect(() => {
        if (id) {
            const request = api("get/obj", {id});
            request.then(setObj, console.error);
            return () => request.abort();
        }
      }, [id]);
      return obj ? <span>{obj.name}</span> : null;
}

documentation fixs

04 Mar 11:46
Compare
Choose a tag to compare
1.0.3

1.0.3

fixs

04 Mar 11:45
Compare
Choose a tag to compare
1.0.2

1.0.2

Fix npm package

01 Mar 13:52
Compare
Choose a tag to compare
1.0.1

verions in example

Initial release

01 Mar 13:52
Compare
Choose a tag to compare
1.0.0

1.0.0