0.0.1-alpha.10 • Published 6 years ago
@infinitescroll/streams-errors v0.0.1-alpha.10
Adding new errors to this package:
- Go to RPCErrorCodes.ts and add the new code and message to the
RPCErrorCodesobject. The number used must be less than -32001 (it should just be the next number down from the last error code, serially). The message should be unique. - Go to
errors.tsand add a new named class that extends the RPCError, passing the new error code you just created. For example:
export class TheErrorYouJustCreated extends RPCError {
constructor({ ...args } = {}) {
super({ code: '-code you just created', ...args })
}
}- Go to
handleErrfunction, and make acasefor your error to be handled.
0.0.1-alpha.10
6 years ago
0.0.1-alpha.6
6 years ago
0.0.1-alpha.7
6 years ago
0.0.1-alpha.4
6 years ago
0.0.1-alpha.2
6 years ago
0.0.1-alpha.1
6 years ago
0.0.1-alpha.0
6 years ago