From 94aaf687ab1f971540d4ca9c8fd6f6809ddc79b4 Mon Sep 17 00:00:00 2001 From: Julien Etienne Date: Tue, 4 Apr 2017 03:09:13 +0100 Subject: [PATCH] Updated readme Removed gulp file Bumped version --- README.md | 28 ++---------------- dist/resizilla.js | 2 +- dist/resizilla.umd.js | 2 +- gulpfile.js | 69 ------------------------------------------- package.json | 8 ++--- 5 files changed, 8 insertions(+), 101 deletions(-) delete mode 100755 gulpfile.js diff --git a/README.md b/README.md index d4a60fb..6f68c9a 100755 --- a/README.md +++ b/README.md @@ -1,25 +1,5 @@ ![img](http://oi68.tinypic.com/33m0pbr.jpg) -```php - *** Important API Changes*** -``` - #### For: - - resizilla.js - - resizilla.es.js - - version 0.7+ requires the Request-frame or an alternative requestAnimationFrame & cancelAnimationFrame polyfill. - - If you need to use both Request-frame and Resizilla check out [4d](https://github.com/envidia/4d) which includes both libraries and weighs under 2kB gzipped. - -- [4d](https://github.com/envidia/4d) -- [requestFrame](https://github.com/julienetie/request-frame) - - #### For: - - resizilla.polyfilljs - - resizilla.polyfill.es.js - - These distributions include the Request-frame polyfill. - ## resizilla ### A Better Window Resize @@ -38,11 +18,9 @@ ____ ``` npm i resizilla --save ``` -##### via bower ``` -bower i resizilla +yarn add resizilla ``` -##### via [src](https://github.com/julienetie/resizilla/tree/master/dist) ____ #### Usage: @@ -67,8 +45,6 @@ or - orientationChange: See below... -_For general use, use a moderate delay e.g. `incept: 200`_ - ____ #### Tested browsers: @@ -108,7 +84,7 @@ The current example only needs to reveal the transition of the debounce to satis #### So no element resize support? -Nope, and with good reason. Elements resize detection is a different paradigm, to detect changes that occur with elements checkout [getComputedStyle](https://developer.mozilla.org/en-US/docs/Web/API/Window/getComputedStyle), [transitionEnd](https://developer.mozilla.org/en-US/docs/Web/Events/transitionend) & [MutationObserver](https://developer.mozilla.org/en/docs/Web/API/MutationObserver). +To detect changes that occur with elements checkout [getComputedStyle](https://developer.mozilla.org/en-US/docs/Web/API/Window/getComputedStyle), [transitionEnd](https://developer.mozilla.org/en-US/docs/Web/Events/transitionend) & [MutationObserver](https://developer.mozilla.org/en/docs/Web/API/MutationObserver). _(Original ASCII art by Mozilla)_ diff --git a/dist/resizilla.js b/dist/resizilla.js index 274d8ce..1b7ad23 100644 --- a/dist/resizilla.js +++ b/dist/resizilla.js @@ -13,7 +13,7 @@ vVVv vVVv ': |_| \_\___||___/_/___|_|_|_|\__,_| '' */ /* - Version: 0.8.0 + Version: 0.8.1 Description: A Better Window Resize Author: Julien Etienne Repository: https://github.com/julienetie/resizilla diff --git a/dist/resizilla.umd.js b/dist/resizilla.umd.js index 07fe3b4..c5c1e02 100644 --- a/dist/resizilla.umd.js +++ b/dist/resizilla.umd.js @@ -13,7 +13,7 @@ vVVv vVVv ': |_| \_\___||___/_/___|_|_|_|\__,_| '' */ /* - Version: 0.8.0 + Version: 0.8.1 Description: A Better Window Resize Author: Julien Etienne Repository: https://github.com/julienetie/resizilla diff --git a/gulpfile.js b/gulpfile.js deleted file mode 100755 index d0c0e55..0000000 --- a/gulpfile.js +++ /dev/null @@ -1,69 +0,0 @@ -var gulp = require('gulp'); -var rename = require('gulp-rename'); -var uglify = require('gulp-uglify'); -var concat = require('gulp-concat'); -var plumber = require('gulp-plumber'); -var notify = require('gulp-notify'); -var header = require('gulp-header'); -var pkg = require('./package.json'); -var bump = require('gulp-bump'); - -var banner = ['/**', - ' * <%= pkg.name %>', - ' * Version: <%= pkg.version %>', - ' * License: <%= pkg.license %>', - ' * Copyright <%= pkg.author %> 2015 - ' + new Date().getFullYear() +' All Rights Reserved.', - ' * github: <%= pkg.repository.url %>', - ' *‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾', - ' */', - '' - ].join('\n'); - - -/** - * src files in order. - */ -var src = [ - // Wrapper start. - './src/amd-wrapper-start.js', - - // RequestAnimationFrame polyfill. - './libs/orientationchange.js', - - // RequestAnimationFrame polyfill. - './libs/request-frame.js', - - // Resizilla for window resize debouncing. - './src/resizilla.src.js', - - // Wrapper end. - './src/amd-wrapper-end.js' -]; - - -gulp.task('build', function() { - return gulp.src(src) - .pipe(plumber({errorHandler: notify.onError("Error: <%= error.message %>")})) - .pipe(concat('resizilla.js')) - .pipe(header(banner, { - pkg: pkg - })) - .pipe(gulp.dest('./dist')) - .pipe(uglify()) - .pipe(header(banner, { - pkg: pkg - })) - .pipe(rename('resizilla.min.js')) - .pipe(gulp.dest('./dist')); -}); - - -gulp.task('default', ['build']); - - -/** - * Watch for changes. - */ -gulp.task('watch', function(){ - gulp.watch(['./src/**.js','./libs/**.js'], ['build']); -}); diff --git a/package.json b/package.json index 2c2e1d3..3bc2d98 100755 --- a/package.json +++ b/package.json @@ -1,12 +1,13 @@ { + "author": "Julien Etienne", "name": "resizilla", "description": "A Better Window Resize", - "main": "resizilla.js", + "main": "dist/resizilla.umd.js", + "jsnext:main": "dist/resizilla.es.js", "directories": { "example": "example" }, "scripts": { - "test": "gulp", "bump": "node ./bump.js", "build": "rollup -c ./rollup/umd.js && rollup -c ./rollup/es.js", "watch": "rollup -c ./rollup/umd.js -w" @@ -25,7 +26,6 @@ "resize events", "mobile resize" ], - "author": "Julien Etienne", "license": "MIT", "bugs": { "url": "https://github.com/julienetie/resizilla/issues" @@ -47,5 +47,5 @@ "set-animation-interval": "^0.0.2", "volve": "^0.0.8" }, - "version": "0.8.0" + "version": "0.8.1" } \ No newline at end of file