Skip to content

Instantly share code, notes, and snippets.

View josemunozr's full-sized avatar
🏠
Working from home

José Muñoz Ruiz josemunozr

🏠
Working from home
View GitHub Profile
@josemunozr
josemunozr / gulpfile.js
Created January 16, 2017 16:30
Example Sass
'use strict';
var gulp = require('gulp');
var sass = require('gulp-sass');
gulp.task('sass', function () {
return gulp.src('./public/sass/index.scss')
.pipe(sass().on('error', sass.logError))
.pipe(gulp.dest('./public/css'));
});
$(function() {
$('a[href*="#"]:not([href="#"])').click(function() {
if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) {
var target = $(this.hash);
target = target.length ? target : $('[name=' + this.hash.slice(1) +']');
if (target.length) {
$('html,body').animate({
scrollTop: target.offset().top - 70
}, 1000);
return false;
@josemunozr
josemunozr / sticky_navigation.js
Created December 9, 2016 23:08
sticky_navigation.js
'use strict';
(function () {
function sticky_navigate() {
var window_top = $(window).scrollTop();
var home_top = $("#home").offset().top;
if (window_top > home_top) {
$(".nav").addClass('stick');
@josemunozr
josemunozr / package.json
Created April 16, 2016 18:53 — forked from razpeitia/package.json
package.json para windows de tvify
{
"name": "tvify",
"description": "Una web app para seleccionar tus shows favoritos",
"version": "0.1.0",
"dependencies": {
"jquery": "^2.1.4",
"page": "^1.6.4",
"qs": "^6.0.0",
"serve": "^1.4.0"
},