This code has now been packaged as a plugin, installable from:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Vue from 'vue' | |
import _ from 'lodash' | |
import { compare, stringify } from 'utils/query' | |
import store from 'app/store' | |
/** | |
* Car loader service | |
* | |
* Removes responsibility of loading cars from the results store | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ----------------------------------------------------------------------------- | |
// utils | |
function isPrime(value) | |
{ | |
for(var i = 2; i < value; i++) | |
{ | |
if(value % i === 0) | |
{ | |
return false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Basic rollup setup for jQuery plugin development: | |
* | |
* - watch src folder | |
* - transpile ES6 to ES5 | |
* - create development version (source maps) | |
* - create production version (minified) | |
*/ | |
// dependencies |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Foo > 1 | |
Bar > 1 | |
Bar (doubled) > 2 | |
Bar (doubled, default message) > New value is: 2 | |
Bar (doubled, custom message) > New custom value is: 2 | |
Bar (doubled, default message, uppercase) > NEW VALUE IS: 2 | |
Bar (doubled, custom message, uppercase) > NEW CUSTOM VALUE IS: 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on run | |
do shell script "open -n /Applications/MPlayerX.app" | |
tell application "MPlayerX" to activate | |
end run | |
on open theFiles | |
repeat with theFile in theFiles | |
do shell script "open -na /Applications/MPlayerX.app " & quote & (POSIX path of theFile) & quote | |
end repeat | |
tell application "MPlayerX" to activate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var $ = jQuery; | |
/** | |
* Upgrade Columns jQuery plugin | |
* | |
* Upgrades colgroup formatting to CSS styles | |
*/ | |
$.fn.upgradeColumns = function() | |
{ | |
// variables |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Vue.component('ratio', { | |
template:'<div class="ratio" :style="style"><slot></slot></div>', | |
props: | |
{ | |
width: | |
{ | |
default :512, | |
type :[String, Number], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// --------------------------------------------------------------------------------- | |
// libs | |
var gulp = require('gulp'), | |
// tools | |
sass = require('gulp-sass'), | |
uglify = require('gulp-uglify'), | |
sourcemaps = require('gulp-sourcemaps'), | |
livereload = require('gulp-livereload'), |