23 added TSLint, but currently there are one rule disabled that I would like to run with "no-unreachable": false.
The reason for that is that it reports false positves, e.g. on code like:
function clear(name?: string) {
if (!trx.completed)
return trx.clear(name);
//Claims this is unreachable.
if (isUndefined(name)) {
forEach(views, (val, key) => {
$view.clear(key);
});
} else {
delete views[name];
raiseUpdated(name);
}
return $view;
};
Need to investigate if forcing the use of {} on all if statements etc. even for one-liners... can make this rule run correctly... we can enforce this by adding the rule: "curly": false,
At the end of the day it's surely a bug in TSLint, and we have the test specs to prove that... (as the code above is actually tested);
23 added TSLint, but currently there are one rule disabled that I would like to run with
"no-unreachable": false
.The reason for that is that it reports false positves, e.g. on code like:
Need to investigate if forcing the use of
{}
on all if statements etc. even for one-liners... can make this rule run correctly... we can enforce this by adding the rule:"curly": false,
At the end of the day it's surely a bug in TSLint, and we have the test specs to prove that... (as the code above is actually tested);