Skip to content

Instantly share code, notes, and snippets.

View fernandoPalaciosGit's full-sized avatar
🎯
Focusing

Fernando Palacios Landi fernandoPalaciosGit

🎯
Focusing
View GitHub Profile
@fernandoPalaciosGit
fernandoPalaciosGit / intersectionObserverProxy.js
Last active February 1, 2020 19:14
Simple Utility to subscribe callback and observe elements with IntersectionObserver API
function getCallback(userCb) {
return function(entries, intersectionObserver) {
entries.forEach(getCheckIntersection(userCb, intersectionObserver));
};
}
function getCheckIntersection(userCb, intersectionObserver) {
return function({isIntersecting, target}) {
if (isIntersecting) {
userCb(target);
var SearchPartModel = require('../modules/models/searchpart.model'),
cons = {
ITINERARY_NAME: 'itinerary',
SEPARATESTAY_NAME: 'separatestay'
},
viewConfig = {
position: 'notmd',
inputType: 'date',
role: 'datepicker',
uiClass: 'calendar-changesearch',
@fernandoPalaciosGit
fernandoPalaciosGit / HEROKU.md
Created February 16, 2016 22:08
Heroku deployment, access and configuration

cambiar cuenta de usuario

$heroku accounts:set [user-name]

repositorio remoto de heroku

$heroku apps:create [name-app] --remote [name-remote]

Assign Addons

$heroku addons:add [name-addon] --app [name-remote]

Set environment variable

@fernandoPalaciosGit
fernandoPalaciosGit / linux-distro.md
Last active December 16, 2015 19:27
linux commands

$lsb_release -a : linux distribution description

$uname -mrs : linux kerner description

@fernandoPalaciosGit
fernandoPalaciosGit / .sublime-keymap.md
Last active December 15, 2015 22:15
sublime, keyboard shorcuts
[
	{ "keys": ["ctrl+shift+ç"], "command": "toggle_comment", "args": { "block": true } },
	{ "keys": ["ctrl+shift+r"], "command": "replace_modified_part" },
	{ "keys": ["ctrl+alt+r"], "command": "goto_symbol_in_project" },
	{ "keys": ["shift+ctrl+m"], "command": "goto_definition" },
	{ "keys": ["ctrl+k", "ctrl+k"], "command": "show_mercurial_menu" },
	{ "keys": ["f7"], "command": "sublimerge_differences_navigator", "context": [
		{"key": "setting.is_sublimerge_view", "operator": "equal", "operand": true}
	]},
@fernandoPalaciosGit
fernandoPalaciosGit / .sass-lint.yml.md
Last active December 15, 2015 22:08
linter sass, sass-lint, rule settings
# https://github.com/CSSLint/csslint/wiki/Rules
# https://github.com/sasstools/sass-lint/tree/develop/docs/rules
files:
  include: 'style/**/*.scss'
options:
  formatter: stylish
  merge-default-rules: false
rules:
  border-zero:
@fernandoPalaciosGit
fernandoPalaciosGit / YAML.sublime-settings.md
Last active December 15, 2015 22:16
sublime, user settings, yalm
{
	"apply_syntax_extensions":
	[
		".gemrc",
		"yml.dist",
		"yml"
	],
	"extensions":
	[
@fernandoPalaciosGit
fernandoPalaciosGit / JSON.sublime-settings.md
Last active December 15, 2015 22:16
sublime, user settings, json
{
	"extensions":
	[
		".jscsrc",
		".jshintrc",
		".csslintrc",
		".bowerrc",
		".eslintrc",
 ".babelrc"
@fernandoPalaciosGit
fernandoPalaciosGit / eslintrc.md
Last active December 15, 2015 22:26
linter javascript, eslint, rules
{	"documentation": "http://eslint.org/docs/rules",
	"extends": "eslint:recommended",
	"rules": {
		"camelcase": 0,
		"curly": 2,
		"brace-style": [2, "1tbs"],
		"quotes": [2, "single"],
		"semi": [2, "always"],
 "space-infix-ops": 2,
@fernandoPalaciosGit
fernandoPalaciosGit / .jscsrc.md
Last active December 15, 2015 22:10
linter javascript, jscs, rules
{
    "requireCurlyBraces": [ "if", "else", "for", "while", "do", "try", "catch"],
    "requireSpaceBeforeKeywords": [ "if", "else", "for", "while", "do", "switch", "return" ],
    "requireSpaceAfterKeywords": [ "if", "else", "for", "while", "do", "switch", "return" ],
    "requireSpacesInFunctionExpression": {
        "beforeOpeningRoundBrace": true,
        "beforeOpeningCurlyBrace": true
    },
    "requireMultipleVarDecl": true,