Read the statement by Michael Teeuw here.
My Setup (or: How crazy I am)
-
Haha. Well it very much helped me, convoluted or not.
But in any case, since electron is essentially a html browser, you can refresh and use a console just like any other browser, which is actually something I didn’t know prior (F5 on Windows and ⌘+R on a Mac)
So with that said, I simply work on my files on my local system and push them to the Raspberry Pi.
Using “npm start” allows me to launch the application on my system, and using “⌘⌥ + I” brings up the console allowing me to debug.
I actually prefer your method :smile: !
-
For me the whole thing is integration. How to get devices integrated into the current ecology without needing additional ‘anything’ to be added. So I didn’t have to install npm nor electron on my work station, I already had all the necessary tools. And why work on separate copies of the software in different locations, that causes confusion later. I keep it all in one location, and use it from there.
And with the addition of Git, even if I horribly break something, I can always revert the code to an earlier state simply by going to Git and checking out an earlier commit state. Instant backup and revision control.
My setup at the office is similar, except instead of the rpi, I have it running as a serveronly on one of my large servers (replace the Raspberry Pi for a server in the layout above). But that’s really the only difference. Everything else is the same.
-
Well thanks to you, I’ve managed to create a semi-functional first module for another user :)
-
I’m glad that has helped you. It doesn’t matter what kind of setup one uses, it’s unique for everyone. So if what you’re doing is working for you, even better. I try not to tell anyone whether something’s better done a different way, I would rather make recommendations and let folks decide for themselves what’s best for them.
-
I just wanted to chime in and say this post also helped me get started. Thank you for the general setup points.
The last issue I had was that when the mirror was doing its thing and displaying content to the monitor, I couldn’t use a browser from my development machine to see the output. And SSH into the Pi wasn’t allowing me to start the mirror service. The browser and Pi just weren’t communicating.
My solution was to run
node serveronly
. This allows me to hit the mirror’s ip address and for my browser to render the mirror content. A quick reboot of the mirror will pop it back into display mode.