Skip to content

observe/polymer: Uppercase and refactor annotation names #15159

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
DartBot opened this issue Nov 19, 2013 · 7 comments
Closed

observe/polymer: Uppercase and refactor annotation names #15159

DartBot opened this issue Nov 19, 2013 · 7 comments
Labels
closed-not-planned Closed as we don't intend to take action on the reported issue

Comments

@DartBot
Copy link

DartBot commented Nov 19, 2013

This issue was originally filed by @seaneagan


issue #0 argued for upper casing the dart:core annotations, but looks like there just wasn't enough time to make that change before 1.0. However, it's not too late to make the same change for observe/polymer:

@observable
@reflectable
@published

->

@observed()
@Reflected()
@published()

and then hopefully later fix issue #2 shortening them to:

@observed
@Reflected
@published

Removing the 'Property' suffix from PublishedProperty and ObservableProperty makes them consistent with the current Reflectable, which could allow them to also be used at the class level to mark all properties as such. And since @­Observable doesn't work, the 'able' suffix doesn't work, but the 'ed' suffix seems to work in all cases, and (FWIW) matches Deprecated.

@jmesserly
Copy link

Personally I doubt 13582 will be fixed. Makes this likely moot.

I don't like "observed" because it hasn't necessarily been observed. And may never be. I think "@published" is the outlier. One idea there was to make it @­attribute.


Added Area-Polymer, Triaged labels.
Marked this as being blocked by #13582.

@sigmundch
Copy link
Member

added also prerequisite on issue #11474, so we first agree on what the style should be before we change it in polymer.


Marked this as being blocked by #11474.

@jmesserly
Copy link

given the convention in corelib already exists, I doubt we'll change this. At least, I'm not seeing a persuasive reason.

(I get that it is familiar from C# and Java, but Dart annotations are full const expressions, so they don't have the same limitations)

@sigmundch
Copy link
Member

Added Library-Observe, Library-Polymer labels.

@anders-sandholm
Copy link
Contributor

Removed Library-Observe label.
Added Pkg-Observe label.

@jmesserly
Copy link

not planned to remove the shorthand forms, but if you prefer you can most certainly use the const ctors instead:

@ObservableProperty()
@reflectable()
@PublishedProperty()

(Note that ObservableProperty couldn't be named Observable as it would conflict with the mixin/base class type.)


Added NotPlanned label.

@DartBot DartBot added Type-Defect closed-not-planned Closed as we don't intend to take action on the reported issue labels May 14, 2014
@DartBot
Copy link
Author

DartBot commented Jun 5, 2015

This issue has been moved to dart-archive/observe#52.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-not-planned Closed as we don't intend to take action on the reported issue
Projects
None yet
Development

No branches or pull requests

5 participants