Starting point for a timing web/mobile app?
August 15, 2020 12:00 PM

I'm looking into building a little tool I've thought about making for years, but lacking anything other than some basic CSS/HTML skills I've never been capable of it. I'd like to build a working prototype that runs in a browser and could conceivably be ported in part or concept to a mobile app. Where should I start as a total newbie? Details inside.

What I'm envisioning is essentially a set of persistent timers that count up from when they were started. I figure it's a matter of storing a starting Unix epoch time and comparing that to the present one, then showing the difference in hours, days, etc. "This timer has been on for 6 days, 5 hours" for instance, with options to delete or make new ones.

I don't need to make this a polished app or anything, I'd just like to run the code and have it online to show that it works. Some day in the future I may work with a developer friend to make a "real" app version but until then I'd like to try making a simple version myself.

Given all this, where would you recommend I start as far as making this happen? I don't mind reading up a bit but really don't have any coding experience so I'd be starting from near zero (I do have a website that can host code). So if you were trying to do this in the simplest way possible, what would you use? Thanks!
posted by BlackLeotardFront to Computers & Internet (4 answers total) 1 user marked this as a favorite
If I was starting from zero, I'd read the javascript page for the Date object:

MDN - Date.now()
or
W3Schools - Date.now()

and run their demo code (both have "run here" or "try it out" links) and start changing it little by little. Throw console.log() calls everywhere where you don't know what's going on. Open up a separate window, and use the links to other Date functions and try to use them in the demo code.
posted by meowzilla at 12:25 PM on August 15, 2020


Once that tiny input box feels too constraining, I'd copy what you have into JSFiddle or make an account on Repl.it.
posted by meowzilla at 12:34 PM on August 15, 2020


In a word, learn javascript. Just about any tutorial will teach you enough in the first or second lesson. You dont say if you want the timing resume time when restarted after a shutdown. For the you need to know how to read and write cookies.
posted by SemiSalt at 5:46 PM on August 15, 2020


Thanks for the responses. I've fiddled a bit with js but never really learned more than modifying existing stuff.

It would be persistently "running," in that it would always show the time since it first was started, not time displayed or whatever. It wouldn't freeze when the tab closed or whatever. That helps keep it simple, I think.

If anyone has any favorite basic javascript starting points/tutorials, fire away!
posted by BlackLeotardFront at 1:11 PM on August 16, 2020


« Older Need to get rid of my loveseat couch in a bind....   |   Canadian-American border closure Newer »
This thread is closed to new comments.