Tutorials Icon

Tutorials

Tutorials for hackers.
5 Stories
All Topics

Jon Skeet codeblog.jonskeet.uk

Storing UTC is not a silver bullet

This is a pretty long post from Jon Skeet on storing and converting UTC. For those interested in more of a tldr, the conclusion at the end of the post is “intended to be read in a standalone fashion.” When I read Stack Overflow questions involving time zones, there’s almost always someone giving the advice to only ever store UTC. Convert to UTC as soon as you can, and convert back to a target time zone as late as you can, for display purposes, and you’ll never have a time zone issue again, they say. This blog post is intended to provide a counterpoint to that advice. I’m certainly not saying storing UTC is always the wrong thing to do, but it’s not always the right thing to do either.

read more

Denny Tek dennytek.com

Building a personal site with Gatsby (part 1)

The goal of this series of blog posts is to create a personal website using Gatsby V2 from the default starter. The final website will have an index page where you can introduce yourself, a list of all blog posts, individual blog pages, tag pages listing blog posts in specific categories, and a projects portfolio page. Here’s all the parts to this deep dive. Part 1: Introduction and Setup Part 2: Styling with Sass/SCSS Part 3: Generating Blog Posts with Markdown Files Part 4: Creating a List of Blog Posts Part 5: Adding Thumbnail Images to a Blog List Part 6: Adding Multiple Responsive Images to a Markdown Blog Post Part 7: Adding Tags to Blog Posts Part 8: Creating a Project Page from JSON data Part 9: Pagination, Deploying to Netlify, and SEO Check out the example repo on GitHub and preview the final website.

read more

Flavio Copes flaviocopes.com

A short and simple guide to Babel

Just getting started with Babel? Read this guide from Flavio Copes — it’s short, so maybe 2-3 minutes to skim or 10 minutes to read. Babel is an awesome tool, and it’s been around for quite some time, but nowadays almost every JavaScript developer relies on it, and this will continue going on, because Babel is now indispensable and has solved a big problem for everyone. Babel is a compiler: it takes code written in one standard, and it transpiles it to code written into another standard.

read more

Zach Holman zachholman.com

UTC is enough for everyone, right?

Programming around time is the bane of pretty much every programmer’s existence. UTC works most of the time, but still has its flaws. Zach Holman writes on his blog: Programming time, dates, timezones, recurring events, leap seconds… everything is pretty terrible. The common refrain in the industry is Just use UTC! Just use UTC! And that’s correct…sort of. But if you’re stuck building software that deals with time, there’s so much more to consider. It’s time…to talk about time. Zach includes a lot of time-related puns and whole lot of wisdom about programming time.

read more

Linux iridakos.com

Full text searching your man pages with Elasticsearch

For those coming off the heels of The Changelog #292 where we talked with Philipp Krenn about Elasticsearch, you’re gonna wanna play around with full text searching your man pages with Elasticsearch. This post covers: Setup an Elasticsearch instance locally Create an index for the data Feed the index with the man pages of the OS Create a search method for full text searching Full text search the man pages

read more

0:00 / 0:00