- Code: Select all
fn(
{
a: 'foo',
b:
{
c: 'bar'
}
})
fn(
{
a: 'foo',
b:
{
c: 'bar'
}
})
callumacrae wrote:Well yeah, they're parentheses to mark an object, not a block of code. Objects always want the parentheses on the same line, as this wouldn't make sense:
- Code: Select all
fn(
{
a: 'foo',
b:
{
c: 'bar'
}
})
<script>
var test =
{
a: 'foo',
b:
{
c: 'bar'
}
};
console.log(test);
var fn = function() {
return
{
a: 'foo'
}
};
console.log(fn()); // undefined
</script>


Oleg wrote:How about requiring all sentences in commit messages to begin with a capital letter (unless the first word is a variable or otherwise something that normally begins with lowercase)?

callumacrae wrote:Oleg wrote:How about requiring all sentences in commit messages to begin with a capital letter (unless the first word is a variable or otherwise something that normally begins with lowercase)?
I've always worked with first letter capital and ending with a full stop wherever possible.
[branch] fixed X error in Y.php) since that didn't look too bad. The purpose of the hard stop and capital letter is to indicate the end of one sentence and the beginning of another. However, in a summary like the one able, neither is needed, imo, since there is only the one sentence.
Return to [3.1/Ascraeus] Merged RFCs
Users browsing this forum: No registered users and 9 guests