Vue Triple Dots
Vue js component for showing html element with dot dot dot (...)
Demo
Setup
NPM
npm install --save vue-triple-dots
Yarn
yarn add vue-triple-dots
Add dependencies to your main.js
:
import Vue from 'vue'
import VueTripleDots from 'vue-triple-dots'
/*
or for SSR:
import VueTripleDots from 'vue-triple-dots/dist/ssr.js'
*/
Vue.use(VueTripleDots)
Note that all props are optional.
Name | Type | Default | Description |
---|---|---|---|
tag | String | 'div' | The element will render. |
ellipsis | String | '...' | 3 dots will show when text has more. |
callback | Function | undefined | |
truncate | string | undefined | |
tolerance | number | undefined | |
keep | string | null | |
watch | string | undefined | |
height | number | undefined | |
readLessKey | string | readLess | |
readMoreKey | string | readMore |
FAQ
Check closed issues with FAQ
label to get answers for most asked questions.
Development
To contribute to the library:
# build main library
npm install
npm run build