How to use the nativescript-vue.filter function in nativescript-vue

To help you get started, we’ve selected a few nativescript-vue examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github jlooper / elocute / mobile-v2 / src / main.js View on Github external
Vue.prototype.$store = store;
Vue.prototype.$routes = routes;
Vue.prototype.$authService = authService
//route manually
Vue.prototype.$changeRoute = (to) => {
  Vue.navigateTo(routes[to])
  }

//TNSFontIcon.debug = true; 
TNSFontIcon.paths = {
  'fa': './font-awesome.css'
};
TNSFontIcon.loadCss();

Vue.filter('fonticon', fonticon)

Vue.use(Vuex)


firebase.init({
  onAuthStateChanged: data => { // optional
    console.log((data.loggedIn ? "Logged in to firebase" : "Logged out from firebase") + " (init's onAuthStateChanged callback)");
    if (data.loggedIn) {
      backendService.token = data.user.uid
      console.log(data.user.uid)
      store.commit('setUser', data.user)
      Vue.navigateTo(Home)
    }
    else {
      backendService.token = ""
      Vue.navigateTo(Login)