Skip to content

Instantly share code, notes, and snippets.

View emirotin's full-sized avatar
🏠
Working from home

Eugene Mirotin emirotin

🏠
Working from home
View GitHub Profile
@htr3n
htr3n / gulpfile.js
Last active October 31, 2021 23:36
Gulp 4 configuration SASS, PostCSS, autoprefixer, cssnano, sourcemaps
const gulp = require('gulp');
const sass = require('gulp-sass');
const postcss = require('gulp-postcss');
const autoprefixer = require('autoprefixer');
const cssnano = require('cssnano');
const sourcemaps = require('gulp-sourcemaps');
const log = require('fancy-log');
const sassSourceFile = 'assets/scss/hyde-hyde.scss';
const outputFolder = 'static/css';
@oroce
oroce / app.js
Created June 17, 2014 08:37
parse csp report in express
var express = require('express');
var app = express();
var bodyParser = require('body-parser');
// chrome sends application/csp-report
// firefox sends application/json
// it seems chrome is doing it well: https://w3c.github.io/webappsec/specs/content-security-policy/
app.use(bodyParser.json({
type: ['json', 'application/csp-report']
}));
App.PickADate = Ember.View.extend({
attributes: ['monthsFull', 'monthsShort', 'weekdaysFull', 'weekdaysShort',
'monthPrev', 'monthNext', 'showMonthsFull', 'showWeekdaysShort', 'today',
'clear', 'format', 'formatSubmit', 'hiddenSuffix', 'firstDay', 'monthSelector',
'yearSelector', 'dateMin', 'dateMax', 'datesDisabled', 'disablePicker'],
events: ['onOpen', 'onClose', 'onSelect', 'onStart'],
tagName: 'input',
classNames: 'pickadate',
@airblade
airblade / application_helper.rb
Created April 7, 2011 10:55
Nested layouts with HAML in Rails 3
module ApplicationHelper
def inside_layout(layout = 'application', &block)
render :inline => capture_haml(&block), :layout => "layouts/#{layout}"
end
end
@shripadk
shripadk / gist:552554
Created August 27, 2010 00:59
Setting up Heroku Hostname SSL with GoDaddy SSL Cert
How to setup Heroku Hostname SSL with GoDaddy SSL Certificate and Zerigo DNS
Heroku recently added an exciting new 'Hostname SSL' option. This option offers the broad compatibility of IP-based SSL, but at 1/5 the price ($20 / month at the time of this writing).
The following tutorial explains how to use Heroku's new 'Hostname SSL' option on your Heroku project. Before we begin, let's list what we're using here:
* Heroku Hostname SSL
* GoDaddy Standard SSL Certificate
* Zerigo DNS