Skip to content

Instantly share code, notes, and snippets.


Yan Sern yansern

View GitHub Profile
yansern / gulpfile.js
Created Dec 4, 2016 — forked from Falconerd/gulpfile.js
Gulp + Watchify + Babelify + BrowserSync
View gulpfile.js
* This gulpfile will copy static libraries and a index.html file as well as
* merge, babelify and uglify the rest of the javascript project.
* - Separate media, libs and src with different watchers.
* - Media and libs should only be copied to dist if they are different sizes.
* The expected project is to be laid out as such:
View normalise-path.php
* Normalise a file path string so that it can be checked safely.
* Attempt to avoid invalid encoding bugs by transcoding the path. Then
* remove any unnecessary path components including '.', '..' and ''.
* @param $path string
* The path to normalise.
* @param $encoding string
You can’t perform that action at this time.