This repository was archived by the owner on May 17, 2019. It is now read-only.
Releases: fusionjs/fusion-plugin-rpc
Releases · fusionjs/fusion-plugin-rpc
v2.1.2
v2.1.1
Changelog
Highlighted Changes
- Fix token type to fix release verification (#162)
Other Changes
- Standardize dependency heading sizes (#168)
- Update dependency rollup to ^0.64.0 (#167)
- Update dependency eslint to v5.3.0 (#166)
- Update dependency flow-bin to ^0.78.0 (#164)
- Fix typo in code example (#165)
- Update dependency eslint-config-fusion to v4 (#163)
- Update uber/web-base-image Docker tag to v1.0.7 (#159)
v2.1.0
v2.0.0
Changelog
Highlighted Changes
- Implement new way of handling error responses (#152)
Other Changes
- Update dependency eslint-plugin-prettier to v2.6.1 (#153)
- Update dependency flow-bin to ^0.75.0 (#150)
- Update uber/web-base-image Docker tag to v1.0.5 (#147)
- Fix Flow complaints (#146)
Migration Guide
Update Handlers to use ResponseError
+import {ResponseError} from 'fusion-plugin-rpc';
const handlers = {
test(args) {
- throw new Error('test');
+ const e = new ResponseError('test');
+ e.code = 'ERRTEST';
+ e.meta = {custom: 'metadata'};
+ throw e;
}
}If you were previously relying on errors propogating up from libraries, you need
to wrap your usage of the library in a try catch and manually throw a
ResponseError. For example:
const handlers = {
test(args) {
- await doThing();
- await doOtherThing();
+ try {
+ await doThing();
+ await doOtherThing();
+ } catch(err) {
+ const e = new ResponseError(err.message);
+ e.code = 'ERRDOTHING';
+ e.meta = {custom: 'metadata'};
+ throw e;
+ }
}
}v1.2.2
v1.2.1
v1.2.0
v1.1.0
Changelog
- Add BodyParserOptionsToken for bodyparser (#132)
- Add .npmrc (#131)
- Update dependency nyc to v11.6.0 (#128)
- Upgrade flow-bin and fusion-core dependencies to ^0.69.0 and ^1.2.1 r… (#127)
- Update dependency eslint to v4.19.1 (#125)
- Update dependency prettier to v1.11.1 (#123)
- Explain RPC (#124)
- Update dependency rollup to v0.56.3 (#107)
- Update dependency eslint-plugin-flowtype to v2.46.1 (#110)
- Update dependency eslint-plugin-react to v7.7.0 (#111)
- Update dependency babel-eslint to v8.2.2 (#112)
- Update dependency eslint to v4.18.1 (#115)
- Update dependency create-universal-package to v3.4.1 (#122)
- Update docs (#121)
v1.0.3
Changelog
- Fix server side routing (#119)
- Remove routePrefix code as the provided fetch should handle it (#114)
- Update dependency flow-bin to v0.66.0 (#108)
- Update dependency eslint to v4.18.0 (#109)
- Update dependency eslint-plugin-flowtype to v2.44.0 (#103)
- Update dependency rollup to v0.56.0 (#105)
- Add issue template (#106)
- Replace FusionJS with Fusion.js (#104)
v1.0.3-1
Changelog
No pull requests in this release