How can i use sails.io.js library?


#1

i always used sails.js frame work for node and it have his own socket.io library
i want to integrate sails.io.js with nativescript app so i can use socket
so any one can help me ?


#2

I’m not familiar with sails. Here is some info though about modules. If they depend on any browser specific API it won’t work with native without changes to remove/bypass those browser APIs. In regard to using some packages, Eddy wrote a plugin that helps with some node packages https://github.com/EddyVerbruggen/nativescript-nodeify/blob/master/README.md

You mentioned socket, there are some web socket libs out there that work with NativeScript if you want to use one of those or look at them. Hope this helps some.


#3

I took a look at the source it will need some tweaking to get that running


#4

And don’t forget that in name of plugin is .js :smiley: And nativescript-nodeify has problem to repair that thing


#5

@markosko I’d like to add that I addressed that issue, and that a fix is available in the @next android runtime, in case you need to use a module with .js (Also npm suggests using dashes instead of dots when naming your modules, just a random piece of info :D)