Socket support
Closed this issue · 3 comments
Thanks a lot for this wonderful project first of all!
I really would love to see an implementation of the standard library socket, so that I could use the require 'socket'
in my code.
Let me know and thanks in advance, cheers!
Sorry for late response. Currently I'm considering two way to implement this:
- To implement async call to Dart so that Socket connection can be done in Dart.
- To support LuaSocket natively, then each call to Lua script may run for a longer time.
Which way do you prefer?
Actually this depends totally on you, I mean I tried to analyse the project but I didn't have too time unfortunately so I can't suggest you which way to take.
Maybe the approach in Dart is safer and more stable, but then is not so native considering Lua, but still could be a nice workaround. Instead on the other side the Lua implementation could be easier but as you said, no as faster as the one in Dart.
Finally I think that both are pretty fine, and I thank you in advance!
A Lua module vmplugin has been added in 0.3.0. It contains invoke_method to call Dart code and more.
A simple http get example is now in the example project.