Skip to content

Instantly share code, notes, and snippets.

@skypanther
skypanther / logger.js
Created January 21, 2012 00:23 — forked from pec1985/app.js
console.log - appcelerator
/*
Custom logger
// usage
var console = require('/logger');
console.log({sdf:"df"}, [1,3,5,6], "sdfsdf");
*/
exports.log = function() {
if(Ti.App.Properties.getBool('production')==false) {
@skypanther
skypanther / app.js
Created February 24, 2012 15:46 — forked from pec1985/app.js
Cache Remote Images
var Utils = {
/* modified version of https://gist.github.com/1243697
* adds detection of file extension rather than hard-coding .jpg as in the original
*/
_getExtension: function(fn) {
// from http://stackoverflow.com/a/680982/292947
var re = /(?:\.([^.]+))?$/;
var tmpext = re.exec(fn)[1];
return (tmpext) ? tmpext : '';
},
@skypanther
skypanther / CIFilter+Extension.swift
Created April 8, 2019 20:28 — forked from ha1f/CIFilter+Extension.swift
CIFilter+Extension.swift
//
// Created by はるふ on 2017/12/11.
// Copyright © 2017年 ha1f. All rights reserved.
//
import Foundation
import CoreImage
import AVFoundation
extension CIFilter {