No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    getting proxied server data to play app

    Quasar Play App
    2
    4
    2363
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      dgk last edited by dgk

      Can’t get play app to pull from my feathers server when it is proxied (works fine within my dev machine).

      Given the IP of my dev machine on the network taken from the QR code I changed the dev config files and restarted the quasar dev, and feathers servers. On my dev machine I can visit the ip address and it all works fine but if I do that in the play app none of the server data dependent rendering happens.

      How do I set up my feathers server to play nice with the quasar play app?? It’s not play app specific issue as the same happens in a browser in my phone but hoping someone here uses feathers and has figured out the right settings. If not I guess I’ll go ask the feathers folks. Basically the proxy appears not to be working across machines.

      WEBPACK/QUASAR CONFIG index.js

          proxyTable: {
        '/api': {
          // target: 'http://localhost:3030',
          target: 'http://192.168.43.114:3030', // samsung phone network
          changeOrigin: true
        }
      

      FEATHERS CONFIG

      {
        "host": "192.168.43.114",
        "port": 3030,
        "public": "../public/",
        "paginate": {
          "default": 100,
          "max": 100
        },```
      1 Reply Last reply Reply Quote 0
      • D
        dgk last edited by

        SOLVED,

        Missed one other place in the feathers client module that needed to be changed. works now.

        import feathers from 'feathers'
        import hooks from 'feathers-hooks'
        import socketio from 'feathers-socketio'
        import auth from 'feathers-authentication-client'
        import io from 'socket.io-client'
        
        // const socket = io('http://localhost:3030', {transports: ['websocket']})
        const socket = io('http://192.168.43.114:3030', {transports: ['websocket']})
        
        const api = feathers()
          .configure(hooks())
          .configure(socketio(socket))
          .configure(auth({ storage: window.localStorage }))
        
        api.service('/users')
        api.service('/switches')
        
        export default api
        
        1 Reply Last reply Reply Quote 0
        • E
          ekoster last edited by

          Hello ‘dgk’. Nice you have this to work. May I ask if you used the feathers-quasar tutorial? I’m also making a quasar app to talk with a feathers backend but keep getting a unexpected token error. Maybe you can help with providing the package.json, router file, and a vue file where you use the api? Thanks

          1 Reply Last reply Reply Quote 0
          • D
            dgk last edited by

            @ekoster I’ve gone way beyond the tutorial at this point.

            I have all the code here. It uses one feathers backend, two nodejs clients, and one quasar client.
            look for frontend(quasar), backend(feathers) switch-controller, and relay-controller (two nodejs clients) repos
            https://github.com/uCOMmandIt

            Eventually I’ll get around to more documentation and some formal sharing in the meantime also see this post.
            http://forum.quasar-framework.org/topic/866/qform-form-fields-generator/5

            1 Reply Last reply Reply Quote 0
            • First post
              Last post