In the Vuex store, I have an action tree structured like this
export const actions: SalaryActionTree<SalaryState, RootState> = {
async setSalaryOperationUnpaidListByUserId(
{commit}, {user_id, pageNum}) {
try {
let res = await SalaryOperationProvider.salaryOperationIndex({
form: {
user_id,
payed: '0',
},
collectable: {pageNum},
});
commit({
type: 'some-mutatation',
data: res.data;
});
} catch (err) {
}
},
}
Is there a way to utilize TypeScript for typechecking of commit parameters here?