#Hello all, I am new to typescript and need some help with unit test, Please help me
11 messages · Page 1 of 1 (latest)
(Please don't wait for someone to volunteer to help before you ask your question)
Okay, what do you have, where are you stuck?
@jolly jasper Looks like that's typed as an object with a function property, not as a function itself.
It's the difference between:
const x = { x: () => { return 0; } {
and
const x = () => { return 0; }
According to your types you have the first one, you probably meant the second one.
@jolly jasper Yeah, I'm saying that's the format you wouldn't want. It's pretty hard to help on the fairly little information you've given, maybe you can make an example that reproduces the issue here: https://www.typescriptlang.org/play
The Playground lets you write TypeScript or JavaScript online in a safe and sharable way.
Nope, please keep questions in the help channels.
Like I said at the start, you need to provide enough information about your question to answer you.
Like I said, if you make an example that reproduces the issue that would help.
I don't think I'm going to be able to help you, though, I'm getting for for the evening soon, but if you leave enough information someone else may be able to.