code: function slugify(val) {
      if (!is_1.isValue(val))
          return null;
      val = val.replace(/^\s+|\s+$/g, '').toLowerCase();
      // replace accents etc.
      var from = 'ãàáäâẽèéëêìíïîõòóöôùúüûñç·/_,:;';
      var to = 'aaaaaeeeeeiiiiooooouuuunc------';
      for (var i = 0, l = from.length; i < l; i++) {
          val = val.replace(new RegExp(from.charAt(i), 'g'), to.charAt(i));
      }
      val = val.replace(/[^a-z0-9 -]/g, '') // replace invalid chars.
          .replace(/\s+/g, '-') // replace whitespace with -
          .replace(/-+/g, '-'); // replace multiple dashes with single.
      return val;
  }
docs: Slugify
  Slugifies string.
  
  @param val the value to be transformed.
  @param def optional default value on null.