Collection of single-HTML file web apps
I've often found myself with a problem that could be solved by a small iOS app I could write, but I don't want to pay $100/year for an Apple developer account just to have my app on my iPhone. Thanks to this Stack Overflow answer, I found out that the Microsoft Edge iOS app supports opening local HTML files and running JavaScript from them. However, everything must be contained in a single HTML file, meaning that you cannot link to other files for CSS, JavaScript, or images. So, I began writing these webapps and wrote a script to compile separate HTML, CSS, JavaScript, and image files into one HTML file that I can then run on my phone.
NOTE: check per-directory README for more information and screenshots of each web app
- WeekDate: quiz to practice calculating the day of the week from any given date
- Flags: quiz to learn flags of all the countries of the world
- install Edge on iOS
- on iPhone, download one of the HTML files in the
resultsdirectory and put it somewhere in your Files app- you can do this by opening the page in Safari, clicking the three dots at the top right, and clicking "Download"
- once the HTML file is in the Files app, long press it and click Share, then select Edge (you may have to click "More" first if Edge is not listed as one of the options)
- then, select "Open in Microsoft Edge" and the local file will be opened
- make sure that your project directory follows the same structure as those in this repository
- this means you must have an
index.html,styles.css,scripts.jsin the directory - images can either be put in a subdirectory or directly in the project directory, but cannot be elsewhere
- this means you must have an
- run
./makeSingleFile.sh name_of_project_directory/to compile and minify your project in one HTML file- note that
makeSingleFile.shuses theminifyNPM library, so you should first install it withnpm install minify - this will put the resulting file in the
resultsdirectory, with the same filename as the project directory you specified
- note that