Skip to content
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

[2.0-preview] can't access to this.$ nodes when providing properties' default values #4160

Closed
valdrinkoshi opened this issue Nov 19, 2016 · 3 comments

Comments

@valdrinkoshi
Copy link
Member

In 1.x one can access to this.$ nodes when providing a property default value, e.g.

properties: {
  button: {
    type: HTMLElement,
    value: function() {
      return this.$.btn;
    }
  }
}

This is no longer possible in 2.x http://jsbin.com/mohotas/4/edit?html,console,output

@sorvell
Copy link
Contributor

sorvell commented Nov 21, 2016

We're inclined to make this a breaking change unless it causes undo harm. This can be done in ready. Will that be sufficient?

@valdrinkoshi
Copy link
Member Author

Setting it on ready is sufficient & doesn't trigger twice observers. @notwaldorf @cdata opinions on this?

@sorvell
Copy link
Contributor

sorvell commented Feb 25, 2017

Looks sufficiently handled. Please re-open if any new issues crop up.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants