Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Bernardo Martín Viudez bermartinv

🏠
Working from home
View GitHub Profile
@bermartinv
bermartinv / key bindings
Created Aug 30, 2017
Caracteriticas de mi sublime
View key bindings
[
{ "keys": ["ctrl+shift+n"], "command": "new_window" },
{ "keys": ["ctrl+shift+w"], "command": "close_window" },
{ "keys": ["ctrl+o"], "command": "prompt_open_file" },
{ "keys": ["ctrl+shift+t"], "command": "reopen_last_file" },
{ "keys": ["alt+o"], "command": "switch_file", "args": {"extensions": ["cpp", "cxx", "cc", "c", "hpp", "hxx", "hh", "h", "ipp", "inl", "m", "mm"]} },
{ "keys": ["ctrl+n"], "command": "new_file" },
{ "keys": ["ctrl+s"], "command": "save" },
{ "keys": ["ctrl+shift+s"], "command": "prompt_save_as" },
{ "keys": ["ctrl+f4"], "command": "close_file" },
View gulpfile.js
var gulp = require('gulp');
var sass = require('gulp-sass');
var uglify = require('gulp-uglify');
var cssnano = require('gulp-cssnano');
var imagemin = require('gulp-imagemin');
var autoprefixer = require('gulp-autoprefixer');
var htmlmin = require('gulp-htmlmin');
var browserSync = require('browser-sync').create();
gulp.task('default', ['css','javascript'], function() {
@bermartinv
bermartinv / packaje.json
Last active Sep 5, 2017
package.json de mi workflow
View packaje.json
{
"name": "pruebas",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "\u001b[A\u001b[A\u001b[A\u001b[A\u001b[C\u001b[B\u001b[B\u001b[D\u001b[Dprueba de gulp\u001b[B\u001b[D\u001b[D\u001b[D\u001b[D\u001bhtml\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[\u001b[B\u001b[C"
},
"author": "Bernardo Martin",
"license": "UNLICENSED",
@bermartinv
bermartinv / style.css
Last active Feb 20, 2018
archivo inicial css
View style.css
html,body{
width: 100%;
height: 100%;
font-family: 'Open Sans', sans-serif
}
*, *:after, *:before{
box-sizing: border-box;
margin: 0px;
padding: 0px;
View @media and viewport .css
/* Definimos todos los tamaños de pantalla */
@media screen and (max-width:320px){}
@media screen and (min-width:320px and max-width:480px){}
@media screen and (min-width:480px and max-width:768){}
@media screen and (min-width:768px and max-width:1024px){}
@media screen and (min-width:1024px and max-width:1200px){}
/* Definimos orientacion del dispositivo */
@media (orientation:landscape){} // posicion horizontal dispositivo
@media (orientation:portrait){} // posicion vertical dispositivo
View reset.css
html{
font-size: 14px;
}
html, body {
width: 100%;
height: 100%;
font-family: "Open Sans", sans-serif;
background-color: #fafafa;
View head.html
<!DOCTYPE>
<!-- Es importante para los buscadores indicar en que idioma creamos la web -->
<html lang="en">
<head>
<title>Titulo de la web y página en concreto</title>
<link rel=”shortcut icon” type=”image/png” href=”/favicon.png”/>
<!-- indica al servidor que el contenido de la página es HTML y codificación de caracteres es UTF-8 -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<!-- Indica que codificación usa esta web -->
<meta charset = "UTF-8" />
View gulpfile.js
var gulp = require('gulp'); // instalar gulp
var sass = require('gulp-sass'); // convertir de sass a css
var autoprefixer = require('gulp-autoprefixer'); // autoprefixer para nuestro codigo css
var browserSync = require('browser-sync').create(); // conectamos a servidor
var htmlmin = require('gulp-htmlmin'); // comprime el html
var imagemin = require('gulp-imagemin'); // comprime imagenes
var uglify = require('gulp-uglify'); // comprime el js
var babel = require('gulp-babel'); // transpile js
var sourcemaps = require('gulp-sourcemaps'); // sourcemaps para js y css, el navegador hace referencia a su linea aunque estén comprimidos
// var jasmine = require('gulp-jasmine-phantom');