Skip to content

Fix type regression in tsnext which throws TS2463 #45

@voxpelli

Description

@voxpelli

The tsnext tests are now failing: https://github.com/voxpelli/pony-cause/runs/7605089081?check_suite_focus=true

index.js(9,25): error TS2463: A binding pattern parameter cannot be optional in an implementation signature.

Happens at:

/**
* @param {string} message
* @param {{ cause?: T }} [options]
*/
constructor (message, { cause } = {}) {

Likely caused by:

Spontaneous thought is that TS has regressed rather than this being a correct error, but have to dig into it.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions