My objective is to define types for my cypress task, written in typescript.
I currently have this when I consume the custom task:
cy.task('customTask').then(v => {
// v is undefined here - how can I configure types?
});
plugins/index.ts
module.exports = (on) => {
on('task', {
customTask: () => {
return 23;
}
});
}