-
Notifications
You must be signed in to change notification settings - Fork 27.4k
fix($resource) add @ support for properties names #11473
Conversation
@mustela, thx for the PR. It generally looks good to me (with a couple of concenrs; see below). I wonder:
|
@gkalpak those are valid comments, and maybe the patter come from the emac standard (?), take a look to this section.
Wondering if this decision really come from that and how strict is angular about it. If we must follow the standard, then this is no longer a bug :) Also about the commit message. I didn't see nothing related to use the "Closes #xxx" sintaxis to automatically close issues. So should it be placed in the Thanks |
@mustela: What this means is: var _test; // OK, because Identifiers are allowed to start with `_`
var @test; // NOT OK, because Identifiers are not allowed to start with `@`
var obj = {_test: null}; // OK, because PropertyName can be an Identifier and
// Identifiers are allowed to start with `_`
var obj = {@test: null}; // NOT OK, because PropertyName can be an Identifier, but
// Identifiers are NOT allowed to start with `@`
var obj = {'@test': null}; // OK, because PropertyName can be a StringLiteral and
// '@test' is a valid StringLiteral So, from that perspective, I think it is pretty safe to allow Regarding the |
@gkalpak you are right, sorry to point the wrong link. I update the branch with the changes. Let me know if you want me to do anything else. Thanks! |
Thx @mustela ! It generally LGTM...buuuut (since you ask for it), I would feel safer having a test that actually uses a |
Add support for properties that starts with @. This is useful when working with BadgerFish convention. Closes angular#10533
@gkalpak your wish is my command! Let me know if thats ok. Thanks! |
Thanks @gkalpak! |
Add support for properties that starts with @. This is useful when working with BadgerFish convention. Closes angular#10533 Closes angular#11473
Add support for properties that starts with @. This is useful when working with BadgerFish convention.