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

Handle atomic blocks without entities #126

Open
makenosound opened this issue Aug 9, 2017 · 1 comment
Open

Handle atomic blocks without entities #126

makenosound opened this issue Aug 9, 2017 · 1 comment

Comments

@makenosound
Copy link
Contributor

Can happen from pasted content sometimes, and we currently expect there to be an entity for each atomic block we parse:

constructor (props) {
  super(props)
  this.entityKey = props.block.getEntityAt(0)
  this.entity = Entity.get(this.entityKey)

  this.state = {
    isSelected: false,
  }
}
@makenosound
Copy link
Contributor Author

Related this we’ll want to handle cases when entities are created, just not in the way that we want. HTML pasted with img tags, for example, will create IMAGE entities and that’s not something we support.

This gist has a potential method for dealing with this issue: https://gist.github.com/stevensacks/86ba98facd349cee678401a030563809

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

No branches or pull requests

1 participant