Does anyone have a suggestion as to where I can direct my attention to? I’m assuming their are modules to help with this, and that I don’t need to code up a 100 percent solution from unix time from scratch.
Edit: the link looks just like I changed the version, but it’s actually #anchored a ways down the page to the right function, ‘strftime’. There are examples like:
Right, in this case the function has relatively long documentation, because there are a lot of options. If you scroll through all of it for that function you’ll see plenty of examples.
I’ve run into this myself. Examples are further down the page, and the exceptions/caveats – the most useful fact given the problem I’m facing at times (!) – is the last sentence of the docs.
Yeah I think the docs for Calendar.strftime/3 could be improved. I’m hoping that making it more clear that the Options section is really about the user_options argument it will make it easier to ignore the Options section and focus on the “Formats”.
So I’ve created a PR that will hopefully make it easier to read/scan/grok the Calendar.strftime/3 docs:
P.S. I also thought about putting an example up higher in the docs but I’m not aware of any other function doc that does that (although perhaps one does exist).
Edit: and the PR is now merged, and it includes an example much further up in the docs