Giter Site home page Giter Site logo

vue-feathers's People

Contributors

sunabozu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

vue-feathers's Issues

ported to modern feathers scaffold and Feathers 3

Hi,

I have spent the last two days learning from your example which has a good starting point but is outdated. I think I have it working on the latest feathersjs. Can we collaborate on this somehow so others don't have to do this? A Vue/Vuex/Feathersjs is a killer combo.

Shared vuex state?

I am not sure why this happens or if this is actually by design (i hope it's not).

Using two browsers i login with two different users. I then navigate to /something on one of the browsers and then it navigates to the same location on the other browsers. In a way it shares the state since if i set a state in vuex on one browsers it updates the store on the other browser as well.

This seems to be related to the vue-feathers and socket.io as a different project that we have that does the same but we don't use feathers in it does not have this behavior.

Anyone experienced this?

Cannot read property 'create' of undefined

I've basically just run through the set up and I cant seem to get the services bound to vue. Any suggestions?

Here's my client setup.

import Vue from 'vue'
import Resource from 'vue-resource'
import Router from 'vue-router'

// Install plugins
Vue.use(Router)
Vue.use(Resource)

// Set up a new router

const Feathers = require('feathers/client')
const hooks = require('feathers-hooks')
const authentication = require('feathers-authentication/client')
const socketio = require('feathers-socketio/client')
const io = require('socket.io-client')

const socket = io('http://localhost:3030/')
const feathers = Feathers()
    .configure(socketio(socket))
    .configure(hooks())
    .configure(authentication({storage: window.localStorage}))
console.log(feathers)
const vueFeathers = require('vue-feathers')

// And plug it in
Vue.use(vueFeathers, feathers)

Heres the component that is calling it.

    export default {
        name: "Chat",

        data() {
             return {
                 message: ''
             }
        },

        methods: {
            send(){
                this.$services.messages.create(this.message);
                console.log(this.$services);
            }
        }
    }

Error in browser

VM1043:1 Uncaught TypeError: Cannot read property 'create' of undefined
    at <anonymous>:1:24

Does not remove listeners properly

In the current code:

server.service(keys[i]).removeListener(ekeys[k], service[ekeys[k]].bind(this))

The bind(this) will create a new function. removeListener expects a reference to an already bound function. You'll have to store references to the functions added in the created hook in order to remove them properly.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.