Skip to content

Instantly share code, notes, and snippets.

View acidbjazz's full-sized avatar
👻

Gerardo Rodríguez acidbjazz

👻
View GitHub Profile
  1. Create new project:
gatsby new project-name
  1. Install packages:
npm i --save gatsby-plugin-react-svg gatsby-source-contentful gatsby-transformer-remark

npm i --save gatsby-plugin-react-leaflet react-leaflet leaflet
@acidbjazz
acidbjazz / .gitignore
Created September 25, 2017 18:28
ignore basic files & folders
node_modules/
debug.log
.vscode/
package-lock.json
@acidbjazz
acidbjazz / .eslintrc
Created September 25, 2017 09:06
configurate atom js eslint (airbnb) overwrite
{
"extends": "airbnb",
"rules": {
"linebreak-style": ["error", "windows"]
}
}
@acidbjazz
acidbjazz / .htaccess
Created September 9, 2017 08:13
leverage browser caching
# ######################################################################
# # WEB PERFORMANCE #
# ######################################################################
# ----------------------------------------------------------------------
# | Compression |
# ----------------------------------------------------------------------
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/plain
@acidbjazz
acidbjazz / fb-api.md
Last active April 16, 2016 08:10
fcbk API test
  1. https://developers.facebook.com/
  2. agregar app: nombre, plataforma (sitio web), crear ID
  3. SDK:JS, insertar luego de
<script>
  window.fbAsyncInit = function() {
    FB.init({
      appId      : '559296987609754',
      xfbml      : true,
      version    : 'v2.6'
@acidbjazz
acidbjazz / tryR.r
Last active April 5, 2016 01:15
R codes
# variables, asignación, vector y secuenciación
x <- c(seq(1,10)) #[1] 1 2 3 4 5 6 7 8 9 10
y <- c(seq(0.1, 1, 0.1)) #[1] 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0
#acceso (índice empieza en 1, no en cero)
#también sirve para editar y agregar valores
y[2] #[1] 0.2
#acceso múltiple y rangos
y[c(2,4)] #[1] 0.2 0.4
@acidbjazz
acidbjazz / slim.md
Last active April 16, 2016 05:49
slim template
@acidbjazz
acidbjazz / gulpfile.js
Last active May 2, 2016 19:16
gulp template
/*
npm init
npm install gulp gulp-sass gulp-autoprefixer gulp-cssnano gulp-rename gulp-concat gulp-uglify gulp-htmlmin gulp-plumber --save-dev
*/
'use strict';
//plugins
var gulp = require('gulp'),
@acidbjazz
acidbjazz / index.html
Last active April 15, 2016 02:27
html5 template
<!doctype html>
<html lang="es">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no">
<meta property="og:title" content="¡large title about app!">
<meta property="og:site_name" content="app name">
<meta property="og:url" content="http://www.app.com">
<meta property="og:description" content="two lines description">
<meta property="og:type" content="website">