Skip to content
This repository has been archived by the owner on Dec 19, 2024. It is now read-only.

Changed parent node access to use Polymer.dom api #66

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

taylorstine
Copy link

When adding a <paper-ripple> dynamically with React in the render method (i.e.)

let component = React.createClass({
   getInitialState: function() {
     return {addIt: false}
   }
   render: function() {
     let node = null;
     if (this.state.addIt) {
       node = <paper-ripple/>
     }
     return <div>{node}</div>
   }
   componentDidMount: function () {
       this.setState({addIt: true})
   }

})

This line gives me an error because this.parentNode is undefined.

Per these specifications I believe a better alternative is to use the Polymer.dom api.

@taylorstine
Copy link
Author

Is anybody reviewing this?

@taylorstine
Copy link
Author

@google ?

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

Successfully merging this pull request may close these issues.

2 participants