Skip to content

Instantly share code, notes, and snippets.

View diegowifi's full-sized avatar

Diego Ponce diegowifi

View GitHub Profile
@diegowifi
diegowifi / gist:5dfcc6d83600e3af2b92
Created March 16, 2015 01:01
Equal height for divs inside a row
/*
* Row with equal height columns
* --------------------------------------------------
*/
.row-eq-height {
display: -webkit-box;
display: -webkit-flex;
display: -ms-flexbox;
display: flex;
}
/** Every element includes borders and padding as part of the width */
*,*:before,*:after {
-moz-box-sizing:border-box;
-webkit-box-sizing:border-box;
box-sizing:border-box;
}
$screen-sm:750px;
$screen-md:970px;
$screen-lg:1024px;
@diegowifi
diegowifi / gist:06dacc97d84a48f5b68f
Created May 7, 2015 00:02
Fix XAMPP's Apache shit on Ubuntu
First you should stop your apache server:
sudo /etc/init.d/apache2 stop
Then stop mysql:
sudo /etc/init.d/mysql stop
sudo /etc/init.d/proftpd stopv
<h2>
1. The Period
</h2>
<blockquote>
It was the best of times,<br>it was the worst of times,<br> it was the age of
wisdom,<br> it was the age of foolishness,<br> it was the epoch of belief,<br> it
was the epoch of incredulity,<br> it was the season of Light,<br> it was the
season of Darkness,<br> it was the spring of hope,<br> it was the winter of
despair,
</blockquote>
<!DOCTYPE html>
<html ng-app="people">
<head>
<meta charset="UTF-8">
<title>FrontEnd Test</title>
</head>
<body ng-controller="PeopleController as people">
<div>
<table border="1">
<tr>
@diegowifi
diegowifi / gist:62f2a5a214cb34f14409
Created December 28, 2015 09:39
Find (and kill) process locking port 3000
Find:
lsof -i :3000
Kill:
kill -9 <PID>
@diegowifi
diegowifi / .csscomb.json
Last active May 10, 2017 02:44
JSON file for CSScomb's configuration, with alphabetical order enabled.
{
"exclude": [
".git/**",
"node_modules/**",
"bower_components/**"
],
"remove-empty-rulesets": true,
"always-semicolon": true,
"color-case": "upper",
"block-indent": " ",
@diegowifi
diegowifi / snippets.js
Created November 17, 2017 19:09
Handy jQuery snippets
// Act on scroll condition
var lastScrollTop = 0;
$(window).on('scroll', function() {
scrollPosition = $(this).scrollTop();
if(scrollPosition < lastScrollTop) { // Do something on scroll up }
else { // Do something on scroll down }
lastScrollTop = scrollPosition;
});
{
"extends": ["airbnb", "prettier", "prettier/react"],
"parser": "babel-eslint",
"rules": {
"react/jsx-filename-extension": [
"error",
{ "extensions": [".js", ".jsx"] }
],
"no-underscore-dangle": [2, { "allowAfterThis": true }],
"prettier/prettier": [
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Page Title</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="styles.css" />
<script src="main.js"></script>