Skip to content

Instantly share code, notes, and snippets.

leostratus /
Created September 21, 2012 01:44
Webkit Pseudo-Element Selectors (Shadow DOM Elements)

An ongoing project to catalogue all of these sneaky, hidden, bleeding edge selectors as I prepare my JSConf EU 2012 talk.

Everything is broken up by tag, but within each the selectors aren't particularly ordered.

I have not tested/verified all of these. Have I missed some or got it wrong? Let me know. - A

A friendly reminder that you may need to set this property on your target/selected element to get the styling results you want:


croxton /
Last active March 3, 2024 18:58 — forked from leevigraham/Generate ssl certificates with Subject Alt Names on
Generate ssl certificates with Subject Alt Names

Generate ssl certificates with Subject Alt Names on OSX

Open ssl.conf in a text editor.

Edit the domain(s) listed under the [alt_names] section so that they match the local domain name you want to use for your project, e.g.

DNS.1   =

Additional FQDNs can be added if required:

joaocunha / How To Hide The Select Arrow On
Last active December 10, 2023 13:05
How to hide <select> dropdown's arrow in Firefox when using "-moz-appearance: none;".

This is no longer a bug. I'm keeping the gist for historical reasons, as it helped to get it fixed. Make sure to read the notes by the end of the post.

How to remove hide the select arrow in Firefox using -moz-appearance:none;

TL;DR (or, the fix)

  1. Set -moz-appearance to none. This will "reset" the styling of the element;
  2. Set text-indent to 0.01px. This will "push" the text a tiny bit[1] to the right;
SerafimArts /
Last active October 22, 2021 21:43
Tips And Tricks: PhoneGap + Mobile Development (~2015 year)
  • На iOS устройствах числовые значения подчёркиваются синим. Эта проблема возникает из-за того, что iOS устройства по умолчанию считают все числа похожие на телефонные номера - телефонными номерами. Решается добавлением <meta name="format-detection" content="telephone=no" /> Тоже самое касается адреса: <meta name="format-detection" content="address=no" />

  • Пользователь может уменьшать и увеличивать приложение. Решается добавляением тега <meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" />

  • Ссылки нажимаются с задержкой (примерно 300ms). Решается подпиской на событие touchstart и принудительной инициализацией события click после него. Если проблема всё равно возникает - ничего не поделать, надо облегчать dom. Как вариант - можно использовать библиотеку, посоветанную @adubovsky ниже в комментариях:

vestman / media-queries.less
Created March 10, 2016 08:58
Less: Mixin for building media queries
// Create media queries
// -
// Live example:
// -
// Example:
// .selector {
// ...
// .Mq(sm; {
// width: 100px;
micho / wysihtml5-resize.js
Created March 29, 2012 20:30
wysihtml5 resize plugin. Depends on jQuery and Underscore
(function () {
var setupRegularResize, setupIframeResize, e;
function bind(a, b) {
return function () {
return a.apply(b, arguments);
setupRegularResize = (function () {
getify / queue.LAB.js
Created November 17, 2010 22:20
adding "queueing" to LABjs dynamically, to be able to simulate the $LAB chain dynamically with a for-loop
<!DOCTYPE html>
<title>LABjs Demo</title>
<script src="/js/queue.LAB.js"></script>
// adding `false` in the queue will signifiy an empty .wait() in the $LAB chain
$LAB.queue("", false);
$LAB.queue("", false);