For example you can write:
/** * Returns the sum of 2 numbers * * @example sum(1, 2) * //=> 3 */ export const sum = (a, b) => { return a + b }
This has been super useful for us because it is cognitively easier to write/run the tests in the context of the function itself.
It's not very well tested with classes, but we are looking for any feedback and will continue to improve.
For example you can write:
And then this library will assert that the @example returns the correct code.This has been super useful for us because it is cognitively easier to write/run the tests in the context of the function itself.
It's not very well tested with classes, but we are looking for any feedback and will continue to improve.