Skip to content

Instantly share code, notes, and snippets.

View andrexduarte's full-sized avatar

André Duarte andrexduarte

View GitHub Profile
{
"remove-empty-rulesets": true,
"always-semicolon": true,
"color-case": "lower",
"block-indent": " ",
"color-shorthand": true,
"element-case": "lower",
"eof-newline": true,
"leading-zero": false,
"quotes": "single",
@andrexduarte
andrexduarte / FB.Canvas.setSize
Created July 24, 2014 18:10
Facebook canvas size
<script type="text/javascript" src="https://connect.facebook.net/en_US/all.js"></script>
<script type="text/javascript" charset="utf-8">
FB.init({appId: 'xxxxxxxxxx', status: true, cookie: true, xfbml: true});
FB.Canvas.setSize({height: XXXX});
</script>
@andrexduarte
andrexduarte / browser-sync.js
Created July 23, 2014 14:13
BrowserSync config
module.exports = {
debugInfo: true,
open: false,
proxy: "localhost.dev",
files: [
'css/*.css',
'*.php'
],
ghostMode: {
clicks: true,
@andrexduarte
andrexduarte / config.rb
Created July 23, 2014 14:12
Compass config
# Require any additional compass plugins here.
require 'sass-globbing'
# Set this to the root of your project when deployed:
http_path = "/"
css_dir = "css"
fonts_dir = "css/fonts"
sass_dir = "sass"
images_dir = "images"
javascripts_dir = "js"
@andrexduarte
andrexduarte / Procfile
Created July 23, 2014 14:10
Foreman Start
browser-sync: browser-sync start --config browser-sync.js
guard: bundle exec guard --group frontend concat linter
@andrexduarte
andrexduarte / Gemfile
Last active August 29, 2015 14:04
Gemfile
source "https://rubygems.org"
gem 'uglifier'
gem 'compass'
gem 'guard'
gem 'guard-shell'
gem 'sass-globbing'
gem 'compass-normalize'
gem 'juicer'
gem 'scss-lint', '~> 0.27.0'
@andrexduarte
andrexduarte / pacotes.md
Last active August 29, 2015 14:04
Meu Sublime Text

Meu Sublime Text

Instale o package control.

Pacotes

  • Alignment
  • All Autocomplete
  • Emmet
@andrexduarte
andrexduarte / vertical-align.scss
Created January 23, 2014 12:41
Vertical-align.
// http://zerosixthree.se/vertical-align-anything-with-just-3-lines-of-css/
%vertical-align {
position: relative;
top: 50%;
-webkit-transform: translateY(-50%);
-ms-transform: translateY(-50%);
transform: translateY(-50%);
}
.element p {
@andrexduarte
andrexduarte / Guardfile
Last active December 24, 2015 14:39
Guard para automatizar tarefas.
group :frontend do
guard 'shell' do
watch %r{.+\.(scss|sass)} do |file|
n file[0], "#{file[0]} changed"
`compass compile --sourcemap`
end
end
# Image optimization
@mixin before-after-background($height, $side-width, $before, $after) {
height: $height;
position: relative;
z-index: 1;
&:before, &:after {
content: '';
display: block;
height: $height;
position: absolute;