RonaldJerez / vue-input-facade

A lightweight and dependency free input masking library created specific for Vue
https://ronaldjerez.github.io/vue-input-facade/latest/
182 stars 27 forks source link

fix(filter): remove unsupported Vue.filter #81

Closed Robo-Rin closed 1 year ago

Robo-Rin commented 1 year ago

Description

Vue 3 upgrade gives errors due to the deprecated Vue.filter. This PR fixes this issue by removing the filter altogether. As mentioned by Ronald further down we can use the already exported masker directly instead.

For example:

<template>
  <div> {{ masker('1234', '###-#').masked }} </div>
</template>

<script>
import { masker } from 'vue-input-facade'

export default {
  setup() {
    return { masker }
  }
}

</script>

Note: Not marking this as a breaking change as the existing beta branch was already broken for Vue 3.

Checklist

github-actions[bot] commented 1 year ago

:tada: This PR is included in version 3.0.0-beta.3 :tada:

The release is available on:

Your semantic-release bot :package::rocket: