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

insert sibling #296

Open
wants to merge 1 commit into
base: mbostock/insert-sibling
Choose a base branch
from
Open

insert sibling #296

wants to merge 1 commit into from

Conversation

Fil
Copy link
Member

@Fil Fil commented Nov 30, 2021

Is this working?

@Fil Fil requested a review from mbostock November 30, 2021 10:36
@Fil Fil mentioned this pull request Nov 30, 2021
return this.insert(name, selectThis);
const create = typeof name === "function" ? name : creator(name);
return this.select(function() {
return this.parentNode.insertBefore(create.apply(this, arguments), this);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, good catch, we need this.parentNode.insertBefore rather than this.insertBefore. I hadn’t tested. 😳

This was referenced Jan 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants