Skip to content

Instantly share code, notes, and snippets.

@limscoder
Last active November 19, 2017 17:41
Show Gist options
  • Save limscoder/b41d2842b88f3f98c88faca18666e20e to your computer and use it in GitHub Desktop.
Save limscoder/b41d2842b88f3f98c88faca18666e20e to your computer and use it in GitHub Desktop.
D3 exit selection
const exitUsers = d3.select('ul.app-user-list')
.selectAll('li.app-user')
.data(users)
.exit();
// remove stale elements from the document
exitUsers.remove();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment