Skip to content

It's not a polyfill #2

@rexblack

Description

@rexblack

This is actually not a polyfill but a ponyfill which then is misleading in the way how to use it.

From a polyfill you would expect to import it like this and all is done:

import 'node-contains';

Instead you will need you use it like this:

import contains from 'node-contains';

if (contains(node, anotherNode)) {
  /* ... */
}

So, please either make it a polyfill by patching Node.prototype or call it a ponyfill.

Of course, best would be to create some kind of documentation... ;-)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions