Skip to content

Instantly share code, notes, and snippets.

Huy Tran htr3n

Block or report user

Report or block htr3n

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
View cmqlstyle.css
html,
body {
font-family: "Helvetica Neue", arial, sans-serif;
font-size: 16px;
line-height: 1.66em;
padding-top: 10px;
padding-bottom: 10px;
background-color: white;
padding: 30px;
}
View gulp-minifying-task.js
const htmlmin = require("gulp-htmlmin");
//...
gulp.task("minify-html", function(done) {
let publicFolder = "./public";
let html = publicFolder + "/**/*.html";
let css = publicFolder + "/**/*.css";
let js = publicFolder + "/**/*.js";
let dest = "./dist";
log("Minifying HTML/CSS/JS in '" + publicFolder + "' to '" + dest + "'");
gulp.src(publicFolder + "/**")
@htr3n
htr3n / remove-git-submodule.md
Last active Jul 27, 2018
Remove git submodule
View remove-git-submodule.md
View keybase.md

Keybase proof

I hereby claim:

  • I am htr3n on github.
  • I am htr3n (https://keybase.io/htr3n) on keybase.
  • I have a public key ASC_QkuVEhTV29hXBa4o6V__M0zHGF5PPqmFsI7xH82S1go

To claim this, I am signing this object:

View most-used-breakpoints.css
/* https://medium.com/@uiuxlab/the-most-used-responsive-breakpoints-in-2017-of-mine-9588e9bd3a8a */
/* a) The Standard Breakpoints. Working with fluid images. */
@media all and (max-width: 1690px) { }
@media all and (max-width: 1280px) { }
@media all and (max-width: 980px) { }
@media all and (max-width: 736px) { }
@media all and (max-width: 480px) { }
View css-breakpoint-mixins.scss
@mixin for-phone-only {
@media (max-width: 599px) { @content; }
}
@mixin for-tablet-portrait-up {
@media (min-width: 600px) { @content; }
}
@mixin for-tablet-landscape-up {
@media (min-width: 900px) { @content; }
}
@mixin for-desktop-up {
View responsive-mobile-first.css
/* Extra small devices (phones, 600px and down) */
@media only screen and (max-width: 600px) {
//...
}
/* Small devices (portrait tablets and large phones, 600px and up) */
@media only screen and (min-width: 600px) {
//...
}
@htr3n
htr3n / gist-theme.css
Last active Jul 22, 2018
A template for Gist theme
View gist-theme.css
/*
* https://github.com/StylishThemes/GitHub-Dark/issues/197#issuecomment-63095957
*/
.pl-coc /* constant.other.color */,
.pl-entl /* entity.name.tag.label */,
.pl-entm /* entity.name.type.module */,
.pl-eoa /* entity.other.attribute-name */,
.pl-mai .pl-sf /* meta.at-rule.include support.function */,
.pl-mm /* meta.module-reference */,
.pl-pdv /* punctuation.definition.variable */,
@htr3n
htr3n / gulpfile.js
Last active Jan 27, 2019
Gulp 4 configuration SASS, PostCSS, autoprefixer, cssnano, sourcemaps
View gulpfile.js
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';
@htr3n
htr3n / package.json
Last active Jul 22, 2018
NPM scripts for running concurrently
View package.json
{
"scripts": {
"scss-build": "gulp scss",
"scss-watch": "gulp watch",
"hugo-watch": "hugo server -w --buildDrafts --cleanDestinationDir",
"dev": "npm-run-all --parallel scss-watch hugo-watch"
},
"devDependencies": {
"autoprefixer": "^9.0.0",
"cssnano": "^4.0.3",
You can’t perform that action at this time.