chore(tooling): remove unused tooling scripts

This commit is contained in:
Adam Bradley
2016-09-13 15:06:03 -05:00
parent 871944b53e
commit 1b65f2d040
2 changed files with 7 additions and 40 deletions

View File

@ -1,6 +1,4 @@
export function noop() {}
/**
* Given a min and max, restrict the given number
* to the range.
@ -91,11 +89,13 @@ export function debounce(fn: Function, wait: number, immediate: boolean = false)
* @param the destination to apply defaults to.
*/
export function defaults(dest: any, ...args: any[]) {
for (let i = arguments.length - 1; i >= 1; i--) {
let source = arguments[i] || {};
for (let key in source) {
if (source.hasOwnProperty(key) && !dest.hasOwnProperty(key)) {
dest[key] = source[key];
for (var i = arguments.length - 1; i >= 1; i--) {
var source = arguments[i];
if (source) {
for (var key in source) {
if (source.hasOwnProperty(key) && !dest.hasOwnProperty(key)) {
dest[key] = source[key];
}
}
}
}
@ -154,34 +154,6 @@ export function pascalCaseToDashCase(val: string = ''): string {
});
}
let uid = 0;
export function nextUid(): number {
return ++uid;
}
/**
* Grab all query strings keys and values.
* @param url
*/
export function getQuerystring(url: string): any {
var queryParams: any = {};
if (url) {
const startIndex = url.indexOf('?');
if (startIndex !== -1) {
const queries = url.slice(startIndex + 1).split('&');
for (var i = 0; i < queries.length; i++) {
if (queries[i].indexOf('=') > 0) {
var split = queries[i].split('=');
if (split.length > 1) {
queryParams[split[0].toLowerCase()] = split[1].split('#')[0];
}
}
}
}
}
return queryParams;
}
/**
* @private

View File

@ -1,5 +0,0 @@
var Generate = require('./generate');
module.exports = {
Generate: Generate,
generate: Generate.generate
};