Newbie Paintball Master

    v-waterfall

    0.1.1 • Public • Published

    v-waterfall

    A waterfall layout component for Vue.js(^2.0)

    Demo

    simple demo

    Installation

    npm install --save v-waterfall

    use

    /* in xxx.vue */
    <template>
        <div>
            /*core code*/
            <Waterfall v-for="(item,index) in items"
                       :maxWidth='240'
                       :gapWidth='20'
                       :gapHeight='20'
                       :resize="true"
                       :height='Math.random() * 200 + 200'
                       :item="item"
                       :index="index"
                       :moduleStyle="$style"
                       uniqueId="xyx"
                       inline-template>
                <div :class="moduleStyle.item" :style="style">
                    {{index}}
                </div>
            </Waterfall>
            </*core code*/>
        </div>
    </template>
    <script>
    import Waterfall from 'v-waterfall'
     
    export default {
      ...
      components: {
        Waterfall,
      }
      ...
    }
    </script>

    Api

    Keywords

    Install

    npm i v-waterfall

    DownloadsWeekly Downloads

    0

    Version

    0.1.1

    License

    ISC

    Last publish

    Collaborators

    • shuxun.yin