I am currently working on a HomeKit project with Espruino WiFi and I'm running some tests first.
However, when I try to do the same inside the Espruino Web IDE, I can not access to the module in require("hap-nodejs"). In the terminal, the npm does everything for me, but here I know I need to introduce the .js file in the module section in Espruino Web IDE, but "hap-nodejs" is not a .js file. I need to transform the "package.json" into my "hap-nodejs.js" so I can use it as a private module. I tried to find a way to do it but nothing seems to work. I also downloaded the .tgz file from "https://www.npmjs.com/package/hap-nodejs", and try to find what I need from there. But it is the same in the end, another package and directories containing the dependencies needed.
My question is: How can I get the module I need (hap-nodejs) to execute "light.js" inside the Espruino?
© Espruino, powered by microcosm.
Report a problem