fd-append

1.0.0 • Public • Published

fd-append

Build Status npm version

append DOM element in a functional way.

Installation

npm install fd-append --save

Usage

let append = require('fd-append')
    , elem = require('fd-elem')
    , appendtoBody = append(document.body);
 
let p = elem('p', 'Meow');
 
appendtoBody(p);
 
assert.equal(document.body.lastChild.innerText, 'Meow'); // true.

API

append :: parent -> child

A curried function that takes in:

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

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

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
1.0.02latest

Version History

VersionDownloads (Last 7 Days)Published
1.0.02

Package Sidebar

Install

npm i fd-append

Weekly Downloads

2

Version

1.0.0

License

MIT

Last publish

Collaborators

  • hemanth