Skip to content

Releases: apicase/core

v0.15 release

20 May 13:54
Compare
Choose a tag to compare

Migration guide

click here

Removed APIs

Removed Requests+

As we said before, Requests+ features are totally removed in 0.15.
Passing options won't do anything.

Removed ApiQueue

After Spawner API release, there are no need in ApiQueue because of duplicated logic.

Removed ApiService

ApiService is now totally removed from @apicase/core package. Use @apicase/services instead.

v0.14 release

29 Apr 11:27
Compare
Choose a tag to compare

New package

Check out @apicase/spawner package that helps you better organise requests queues and create debounced requests.

Deprecations

Requests+ features are now deprecated

Use @apicase/spawner instead

ApiService moved from @apicase/core to @apicase/services

Core still has ApiService but will be totally removed in 0.15.
Also, new ApiService(adapter, options) syntax is no longer supported in @apicase/services

NOTE: These changes are compatible with previous version.
You'll get soft warnings with migration info.
Backward compatibility will be broken in 0.15

v0.13 release

21 Apr 18:24
Compare
Choose a tag to compare

New features

Service.use(cb) - calls cb with a copy of service and returns its result (#14)
You can now move part of logic in "plugins"

Bug fixes

Returned retry method for fail hooks (#19)

Deprecations

ApiService now accepts adapter as a property of options instead of first argument:

- new ApiService(fetch, {
+ new ApiService({
+   adapter: fetch,
    url: '/api'
  })

You'll get a soft warning. In future releases, it won't work.
It was made to allow changing adapters (may be useful in tests to use fake adapter instead of real)

v0.12 release

08 Apr 16:20
Compare
Choose a tag to compare

New features

  • Improved hooks debugging. Now Apicase logs hooks call stack on errors (see changes)

Bug fixes

  • none

Other changes

  • Fully refactored hooks, fixed request flow.

v0.11 release

04 Apr 09:07
Compare
Choose a tag to compare

New features

  • none

Bug fixes

  • FIxed #13 issue

Other changes

  • none

v0.10 release

02 Apr 13:33
Compare
Choose a tag to compare

New features

  • none

Bug fixes

  • Using done/fail in hooks cause request never resolve because of changing promise. Now it works correctly.

Other changes

  • none

v0.9 release

30 Mar 22:06
4c6c10a
Compare
Choose a tag to compare

New features

  • none

Bug fixes

Payload normalisation

You probably could get unexpected behaviour with no headers in request or smth else
It was happening because adapter.convert was being called before calling before hooks.
Now adapter.convert is called only inside adapter request.
You can see new behaviour here

Note that payload.headers.token = token in hook will cause error if you don't pass headers (no adapter.convert called).
Use payload.headers = { ...payload.headers, token } instead

Other changes

  • none

v0.3 beta

29 Oct 21:39
Compare
Choose a tag to compare

New features

Changes

  • Fetch adapter no longer applies JSON.stringify to body object. Use interceptors instead.

v0.2 release

15 Oct 15:26
Compare
Choose a tag to compare

New features

  • Adapter now takes additional instance option with Apicase instance. It may be useful for high order adapters
  • Apicase.install and Apicase.extend now takes additional options argument that will be passed to installer as a second argument