coreybutler / fenix

A simple and visual static web server with collaboration features.
https://preview.fenixwebserver.com
GNU General Public License v3.0
1.65k stars 135 forks source link

Using Fenix to share an USB embedded website #71

Closed Sephi-Chan closed 7 years ago

Sephi-Chan commented 7 years ago

Hello,

I have a single page application (using React) that fetches data from a json file (data.json) that acts as a database. The directory structure is like :

MyApp
├── Fenix.app // For Mac users.
├── Fenix.exe // For Windows users.
├── app.js
├── data.json
├── index.html
└── react.js

My goal is to share it with my colleagues (teachers with nearly no skill with computers), so they can use it like it:

I would like to embed the minimal configuration so they really have nothing more to do than executing Fenix.exe.

I can't do it now since they need to create the server in Fenix before running it. Would it be possible to embed such configuration?

Thanks!

coreybutler commented 7 years ago

As much as I like promoting Fenix, this probably isn't a good case for it. Personally, I'd setup a small Electron app, which is better for distribution. You could embed the same web server from the Fenix code, or use something like ExpressJS.

If you really, really want to use Fenix, then I would suggest looking into the API, which is documented in the wiki. You can use it to programmatically launch a web server for your users. Again though, I think Electron or NW.js are a better fit for your audience.

Sephi-Chan commented 7 years ago

Thanks @coreybutler i'll read about Electron. Good luck with Fenix!