Skip to content

Uncaught NotFoundError: Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node. #52

@vlopato

Description

@vlopato

Hi!

I try to use your module in the my app (angularjs + requirejs). And I got an error in the Chrome:

Uncaught NotFoundError: Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.

It happens in the following code:

  script.onload = function () {
    if (removed) return;
    removed = true;
    >>body.removeChild(script);
    callback();
  };

Script loaded correctly but in the parentElement of script object I can see null. I don't know why but seems like script is not appended to body node.

If I comment this line all works correct.

Thank for your work!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions