Skip to content

Instantly share code, notes, and snippets.

Stefan Baumgartner ddprrt

Block or report user

Report or block ddprrt

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
ddprrt / all-elements.ts
Created May 27, 2020
All HTML Element types
View all-elements.ts
type AllElements = {
'a': HTMLAnchorElement;
'div': HTMLDivElement;
'span': HTMLSpanElement;
'ul': HTMLUListElement;
'title': HTMLTitleElement;
'textarea': HTMLTextAreaElement;
'template': HTMLTemplateElement;
'tfoot': HTMLTableSectionElement;
'thead': HTMLTableSectionElement;
ddprrt / typedef.js
Created Jul 15, 2019
My code shares on Twitter. As a gist. Primarily for #a11y
View typedef.js
* @typedef {Object} Article
* @property {string} title
* @property {number} price
* @property {number} vat
* @property {number} stock
* @property {string} description
/** @type {Article} */
let article;
View index.html
<input type="color" />
ddprrt / Gulpfile.js
Created Oct 29, 2015
Gulp task system and Promises
View Gulpfile.js
* Bluebird allows us to promisify existing Node.js
* technologies. So fs.writeFile and fs.readFile
* are usable with Promises.
* `fetch` fetches Ressources. This code fetches
* jQuery, and saves the responses body in a file
var gulp = require('gulp');
ddprrt / Gulpfile.js
Last active May 8, 2020
Gulp: Grabbing JavaScript assets from a CDN to add to your build pipeline
View Gulpfile.js
var gulp = require('gulp');
var source = require('vinyl-source-stream');
var request = require('request');
var merge = require('merge2');
var concat = require('gulp-concat');
var buffer = require('gulp-buffer');
* 1. We request the latest jQuery version from the jQuery CDN. The
* request package allows for streaming. What we get in return
View lessig.less
@color: blue;
body {
background-color: @color;
ddprrt / Gruntfile.js
Created Feb 13, 2015
Short LESS/Sass Gruntfile
View Gruntfile.js
'use strict';
module.exports = function(grunt) {
sass: {
View lessig.less
p, li, figure, h1, h2, h3, h4 {
& + & {
margin-top: 1em;
You can’t perform that action at this time.