A fast website is essential for a good user experience (UX), conversion and findability.
Performance == User Experience == Conversion
For real-world examples of this see https://wpostats.com/
# From: https://www.smashingmagazine.com/2014/05/proper-wordpress-filesystem-permissions-ownerships/ | |
# CAREFULL! This searches from current path (.) | |
# Files: 644 | |
sudo find . -type f -exec chmod 644 {} + | |
# Folders: 755 | |
sudo find . -type d -exec chmod 755 {} + |
# imapsync - https://imapsync.lamiral.info/ | |
# Sync IMAP mailboxes between hosts | |
# Run through Docker | |
# Some Documentation: https://imapsync.lamiral.info/doc/TUTORIAL_Unix.html | |
# --dry —> DRY-RUN, NO ACTUAL CHANGES (YET) | |
# --search —> "SENTSINCE 1-Jan-2021", Get new-ish mail only | |
docker run gilleslamiral/imapsync imapsync \ | |
--dry \ | |
--host1 mail.HOST1.com \ | |
--user1 USER_HOST1 \ |
// Test (ignoreme) | |
(function(win,doc){ | |
var sc = doc.getElementById('myScript'); | |
if (sc) { | |
var el = doc.createElement('p'); | |
el.innerHTML = 'Yo, this is from the <b>SCRIPT</b> include! :-)'; | |
el.style.color = 'green'; | |
/** | |
* getSiblings(element) | |
* | |
* @param {HTMLElement} HTML Element to find siblings of | |
* @returns {Array} HTML sibling elements of `element` | |
* | |
* Based on: https://twitter.com/ChrisFerdinandi/status/1037350582887927809 | |
*/ | |
const getSiblings = (elem) => { | |
// Return empty Array when given Element is not given or not a HTML Element |
/** | |
* Log highest z-index used on page | |
* @author: davidhund / @valuedstandards | |
* | |
* Do not use this in (production) JS code! | |
* To be used as e.g. a Chrome Devtools snippet, bookmarklet etc.. | |
*/ | |
(function(w,d,z) { | |
console.log(`Highest z-index in use is: %d`, | |
Math.max(... |
/** | |
* Make AJAX call for JSON resource | |
* Supports IE11 and browsers that do not allow responseType='json'. | |
* https://mathiasbynens.be/notes/xhr-responsetype-json | |
* ----------------------------------------------------- */ | |
var getJSON = function(url, successHandler, errorHandler) { | |
var xhr = typeof XMLHttpRequest != 'undefined' ? new XMLHttpRequest() : new ActiveXObject('Microsoft.XMLHTTP'); | |
var supportsJSON = (function() { | |
if (typeof XMLHttpRequest == 'undefined') { return false; } |
/** | |
* Get URL parameters from String | |
* source: https://css-tricks.com/snippets/javascript/get-url-variables/ | |
* @param {String} url The URL | |
* @return {Object} The URL parameters | |
*/ | |
var getParams = function (url) { | |
var params = {}; | |
var parser = document.createElement('a'); | |
parser.href = url; |
var unified = require('unified'); | |
var createStream = require('unified-stream'); | |
var parse = require('rehype-parse'); | |
var rehype2retext = require('rehype-retext'); | |
var rehype2remark = require('rehype-remark'); | |
var remarkStringify = require('remark-stringify'); | |
var retextStringify = require('retext-stringify'); | |
var english = require('retext-english'); | |
// Why does the following (2remark) work (output MD) |
A fast website is essential for a good user experience (UX), conversion and findability.
Performance == User Experience == Conversion
For real-world examples of this see https://wpostats.com/
/** | |
* = PRINT styles | |
* | |
* - Imported in global.css (http://www.phpied.com/delay-loading-your-print-css/) | |
* - Taken straight from: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css#L197 | |
* | |
* @TODO: | |
* - Add to this? | |
* | |
* ========================================================================= */ |