Skip to content

Instantly share code, notes, and snippets.

@RossTeek
RossTeek / gulpfile.js
Created April 7, 2016 09:33 — forked from torgeir/gulpfile.js
Example gulpfile.js
// Load plugins
var gulp = require('gulp'),
sass = require('gulp-ruby-sass'),
autoprefixer = require('gulp-autoprefixer'),
minifycss = require('gulp-minify-css'),
jshint = require('gulp-jshint'),
uglify = require('gulp-uglify'),
imagemin = require('gulp-imagemin'),
rename = require('gulp-rename'),
clean = require('gulp-clean'),
var gulp = require("gulp"),
browserSync = require('browser-sync');
// Сервер
gulp.task('server', function () {
browserSync({
port: 9000,
server: {
baseDir: 'app'
}
@RossTeek
RossTeek / CSS - clearfix
Last active March 30, 2016 06:31 — forked from kovaldn/CSS - clearfix
CSS - clearfix
.clearfix:before,
.clearfix:after {
content: " "; /* 1 */
display: table; /* 2 */
}
.clearfix:after {
clear: both;
}
// html
<label for="year">Год</label>
<select name="year" id="year"></select>
<label for="month">Месяц</label>
<select name="month" id="month">
<option value = "1">01</option>
<option value = "2">02</option>
<option value = "3">03</option>
<option value = "4">04</option>
@RossTeek
RossTeek / Javascript: scroll up button.js
Created March 27, 2016 12:24 — forked from kovaldn/Javascript: scroll up button.js
Javascript: scroll up button.js
// scroll up-------------------------------------
$(window).scroll(function(){
if ($(this).scrollTop() > 100) {
$('.scrollup').fadeIn();
} else {
$('.scrollup').fadeOut();
}
});
$('.scrollup').click(function(){
@RossTeek
RossTeek / CSS: media queries.css
Created March 27, 2016 12:24 — forked from kovaldn/CSS: media queries.css
CSS: media queries.css
/* Smartphones (portrait and landscape) ----------- */
@media only screen
and (min-device-width : 320px)
and (max-device-width : 480px) {
/* Styles */
}
/* Smartphones (landscape) ----------- */
@media only screen
and (min-width : 321px) {
@RossTeek
RossTeek / main.css
Created March 27, 2016 12:23 — forked from kovaldn/main.css
CSS: footer
<div class="wrapper">
<div class="main-content">
</div>
</div>
<footer class="page-footer">
</footer>
/* прибьём футер к низу*/
.wrapper{