Closed johnblommers closed 4 days ago
cd
to the Hurmet site
directory and run node server.cjs
. Then open a browser and navigate to http://localhost:8000/
.
Two other options for running Hurmet locally:
cd
to the Hurmet preview
directory instead of site
. Then node server.cjs
will serve a non-minified version of the code. You'll lose access to other pages such as the documentation.
If you are not connected to the Internet, another option is to just open your browser and navigate to hurmet.org. Hurmet is a progressive web app and it stores a version of itself on your local drive for offline use. The offline version has just the home page, not the documentation.
cd
to the Hurmetsite
directory and runnode server.cjs
.
The problem is that there is no server.cjs
file in the site
directory. Perhaps I have missed a step. Here is what I've tried (with Node.js version v21.7.3 and yarn 3.2.2) :
git clone https://github.com/ronkok/Hurmet.git
cd Hurmet
yarn install
yarn run build
Ah, I see now that I have server.cjs
listed in my gitignore
file. That's my bad. I'll fix it later today.
Just out of curiosity, is there any particular reason why a local run must involve Node? If I were to make the web app's offline version more robust and have the documentation available offline, would that be sufficient to meet your local needs?
Just out of curiosity, is there any particular reason why a local run must involve Node? If I were to make the web app's offline version more robust and have the documentation available offline, would that be sufficient to meet your local needs?
Yes, absolutely, it would be great not to involve Node at all, indeed that complicates matters. A progressive web app honors the "local-first" principle nicely.
Thanks for the feedback. I'll go to work on that web app upgrade. Service workers are a little tricky and I have other things going on so this may take a few days.
Ah, I see now that I have
server.cjs
listed in mygitignore
file. That's my bad. I'll fix it later today.
Excellent, that did the trick :-)
I've upgraded the Hurmet PWA. The main documentation page is now available offline. I've also added Node.js instruction the README page.
Enjoy your offline work!
It's not clear to me how to install and run this project. I already have Node.js installed and working on PopOS 22.04 (based on Ubuntu 22.04).
What does one do after cloning the repository to run Hurmet locally? Thanks in advance!