6 ms·
I've found another issue where it just removes comments entirely inside an otherwise empty block. function doSomething() : int { return myPromise
by gopher_protocol 10y ago
I've found another issue where it just removes comments entirely inside an otherwise empty block.
function doSomething() : int {
return myPromise
.then(() => {
// ...do thing
/* what */
})
.catch(() => {
// ..do other thing
/* the heck */
});
}
becomes
function doSomething(): int {
return myPromise
.then(() => {})
.catch(() => {});
}
Still a very nice pretty printer, though.
- dgreensp 10y agoI used Recast on a codebase at work to migrate to a new code style, and I ran into a long tail of issues with preserving comments that looked like they would require some significant work to fix. I know the author of Recast (Hi Ben) and corresponded with him a little bit about it at the time.