component-align

0.0.1 • Public • Published

Align

Align one element to another with specified position.

Install

npm install component-align

Example

var align = require('component-align')
var yellow = document.getElementById('yellow')
var blue = document.getElementById('blue')
align(yellow, blue, 'bl-tl')

API

align(fromEl, toEl, position)

position could be 'tl', 'tc', 'tr', 'bl', 'bc', 'br', 'lc', 'rc'

/component-align/

    Package Sidebar

    Install

    npm i component-align

    Weekly Downloads

    1,071

    Version

    0.0.1

    License

    MIT

    Last publish

    Collaborators

    • chemzqm