387 private links
loading=lazyattribute to defer the loading of the image until the user scrolls to them<datalist>element to create native HTML autocomplete- Email, call and SMS links
- Ordered lists
startattribute to change the starting point of an ordered list. <input type="reset" />to get a clear button for the forms<meter>element to display quantitieswindow.openerreturns the original page of atarget="_blank". This can have security and performance implications. Includerel="noopener"orrel="noreferrer"to prevent this.<base target="_blank">in the<head>to open all links in the document in a new tab.- Favicon cache busting by adding a
?v=2to the link of the favicon <details><summary>Summary</summary><p>Details</p></details>downloadattribute to a link download the file instead of navigating to it- Use the
webpimage format to boost performance - Use the
posterattribute to specify an image to be shown while the video is downloading, or until the user hits the play button - Use the
spellcheckattribute to define whether the element may be checked for spelling errors.
👍
The first rule of thumb:
If you’re stuck for over an hour, seek help.
with
When you seek advice, first write down everything you’ve tried.
that as 3 benefits:
- act as a rubber duck debugging
- evidence that there is some kind of structured thought process that has been carried out, and what it was
- saving time explaining the context to someone else
If this is not useful enough, the author recommends to use his formula.
About the workflow with Git and best practices 👍
I will start using it. It seems useful if you give your email address to third-parties or to know where someone got your email from.
Solution: Using 1 subgrid per element inside a grid.
In the console: $0.offsetParent → $0 is the currently set element.
Then we can use the offsetParent object property to find the closest ancestor to that element that has its position set to something other than static.
Solutions:
-
styling it manually through CSS :
input:focus { outline: 2px solid deeppink; } -
A keyup tab event listener. Think about adding the class through JS, that way the focus will still be accessible if JS fails to load.
-
the property
::focus-visible
The background color of checkboxes will be the one determined by accent-color. Nice !
And the surrounding stays accessible whatever this color is as the webbrowsers have their own implementation of this.
touch {hero,lightbox,form,another-component}.njk
When to use the drop-shadow filter:
- on a non-rectangular shadow (or clipped elements)
- on a group of box
Limitation: it does not have the spread parameter.
html {
max-width: 70ch;
padding: 3em 1em;
margin: auto;
line-height: 1.75;
font-size: 1.25em;
}
and 100 more bytes:
h1,h2,h3,h4,h5,h6 {
margin: 3em 0 1em;
}
p,ul,ol {
margin-bottom: 2em;
color: #1d1d1d;
font-family: sans-serif;
}Testomony and feedback after 100 posts written.
Here the tips I find relevant for myself:
*Write about the topic, even if it has been covered elsewhere. Your perspectives, experiences, and understanding are the unique bit. People want to read your work.
- Learn to identify the difference between constructive criticism and unproductive harassment. It’ll help you focus on what matters and not waste time and energy.
- Get comfortable getting rejected. While the sting never really goes away, you do grow a thicker skin.
- Read your writing out loud to yourself before publishing it.
- Read it out loud again.
How to hide desktop icons on ubuntu (on 21.04):
sudo apt install gnome-shell-extension-prefs
gnome-shell-extension-prefs
Deactivate Desktop Icons NG (DING)
Older methods does not seems to work (gnome tweak tools, etc...).
How to disappear from Google searches:
<meta name="googlebot" content="noindex">
Your docs belong in the code repository
Your docs is not extracted from code
Your docs features examples
You document every API call you provide
Your docs is easily accessible and browsed
Your docs should be easy to contribute to
and the example of curl.
That way in a moment of full-disk crisis I can simply delete it and buy myself some critical time to debug and fix the problem. 8GB is a significant amount of space, but storage is cheap enough these days that hoarding that much space is basically unnoticeable... until I really need it.
Only one same job at a time ?
My solution to deal with this is to bind an IPv6 localhost ::1 socket to a given port. Only one process can do this, and thus it’s a very effective mutex. No lock files to cause havoc, no dealing with the dark and buggy corners of advisory file locking.
For shell scripts, simply replace the #!/bin/sh with #!/somewhere/bin/lock 2048 where 2048 is the port number you will use to enforce the lock (greater than 1024 if you do not want to deal with the hassles of privileged ports).
31 tips after 10,000 hours of programming.
Takeaways:
- It is possible to list a directory with 8 million files in it.
- strace is your friend
- Don't be afraid to compile code and modify it (hell, simple C compiles so fast it could be interpreted)
- There is no good reason to have 8 million files in a directory :-), but this was a good learning experience (and possibly a good interview question).
The last point is the most important :D
$'$HOME' expands escape sequences like \n or \'