;(function () {

  var vueTruncate = {}

  vueTruncate.install = function (Vue) {
    
    /**
     * 
     * @param {String} value
     * @param {Number} length
     * @param {String} clamp
     * 
     */

    Vue.filter('truncate', function (text, length, clamp) {
      clamp = clamp || '...'

      return text.length > length 
        ? text.slice(0, length - clamp.length) + clamp
        : text
	  })
  }

  if (typeof exports == "object") {
    module.exports = vueTruncate
  } else if (typeof define == "function" && define.amd) {
    define([], function(){ return vueTruncate })
  } else if (window.Vue) {
    window.VueTruncate = vueTruncate
    Vue.use(VueTruncate)
  }

})()
;(function () {

  var vueTruncate = {}

  vueTruncate.install = function (Vue) {
    
    /**
     * 
     * @param {String} text
     * @param {Number} length
     * @param {String} clamp
     * 
     */

    Vue.filter('truncate', function (text, length, clamp) {
      clamp = clamp || '...'

      return text.length > length 
        ? text.slice(0, length - clamp.length) + clamp
        : text
	  })
  }

  if (typeof exports == "object") {
    module.exports = vueTruncate
  } else if (typeof define == "function" && define.amd) {
    define([], function(){ return vueTruncate })
  } else if (window.Vue) {
    window.VueTruncate = vueTruncate
    Vue.use(VueTruncate)
  }

})()
Fix function params doc