I have a .ts file where I have defined and exported two functions as follows:
export const foo = () => { ... }
export const bar = () => { ... }
The code works as expected and I am able to import these functions to other files.
However, when I run lint, eslint throws an error Unexpected chained assignment no-multi-assign
The compiled javascript code in fact shows chained assignment as follows:
exports.foo = exports.bar = void 0;
I could specify a eslint rule to disable the error, but I was wondering if someone could help me understand if I should be doing something differently to write a better syntax.
Note I also tried following with same result:
const foo = () => { ... }
const bar = () => { ... }
export {foo, bar}