Nondeterministic Polynomial Munchies
    Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    fd-prependpublic

    fd-prepend

    Build Status npm version

    prepend DOM element in a functional way.

    Installation

    npm install fd-prepend --save

    Usage

    let prepend = require('fd-prepend');
    let elem = require('fd-elem');
    let prependtoBody = prepend(document.body);
     
    let p = elem('p', 'No, I am');
     
    prependtoBody(p);
     
    assert.equal(document.body.firstChild.innerText, 'No, I am'); // true.

    API

    prepend :: parent -> child
    

    A curried function that takes in:

    • parent -> DOM element to which the child must be prepended.

    • child -> DOM element that needs to be prepended.

    Keywords

    install

    npm i fd-prepend

    Downloadsweekly downloads

    3

    version

    1.0.0

    license

    MIT

    repository

    githubgithub

    last publish

    collaborators

    • avatar
    • avatar