getting proxied server data to play app
-
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 },```
-
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
-
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
-
@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/uCOMmandItEventually 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