Skip to content

Instantly share code, notes, and snippets.

💭
🛠⚡️🔥

Jake Johnson fastdivision

💭
🛠⚡️🔥
Block or report user

Report or block fastdivision

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@fastdivision
fastdivision / class-wc-taxjar-integration.php
Last active Jul 22, 2019
TaxJar WooCommerce Plugin v1.6+ Shipping Overrides
View class-wc-taxjar-integration.php
<?php
/**
* Manually override shipping taxability in TaxJar for WooCommerce
* Tweak class-wc-taxjar-integration.php around line 332
* https://github.com/taxjar/taxjar-woocommerce-plugin/blob/1.6.1/includes/class-wc-taxjar-integration.php#L332
*/
// Make shipping taxable
if ( 'AZ' == $to_state ) {
$taxes['freight_taxable'] = 1;
View custom-headers-example.php
<?php
$client->setApiConfig('headers', [
'X-TJ-Expected-Response' => 422
]);
@fastdivision
fastdivision / userstyle.css
Last active Jun 5, 2017
Sane Flowdock Redesign with Stylebot (Browser) or userstyle.css (Native Flowdock OS X App)
View userstyle.css
/*
* Sane Flowdock Redesign Overrides
* Option 1: Copy and paste CSS into Stylebot
* Option 2: Save file as `userstyle.css` inside ~/Library/Application Support/Flowdock, hit CMD+R to reload app
*/
body {
font-family: -apple-system, BlinkMacSystemFont, Arial, Helvetica, sans-serif !important;
}
View keybase.md

Keybase proof

I hereby claim:

  • I am fastdivision on github.
  • I am jakejohnson (https://keybase.io/jakejohnson) on keybase.
  • I have a public key ASBtvoDpFqgn0MlR2KxjeWRRMY8BJUeAfW7KXMBgx42k_wo

To claim this, I am signing this object:

@fastdivision
fastdivision / Smartcalcs.php
Last active Feb 13, 2017
Magento + TaxJar Custom Product Taxability Exceptions by State
View Smartcalcs.php
<?php
// Include around here:
// https://github.com/taxjar/taxjar-magento-extension/blob/master/app/code/community/Taxjar/SalesTax/Model/Smartcalcs.php#L236
// Taxable in one state, exempt in other exempt states
$specialTaxableProducts = array(1001, 1002, 1003, 1004); // Product IDs
// Tax these clothing products if shipped to PA
if (in_array($item->getProductId(), $specialTaxableProducts) && $address->getRegionCode() == 'PA') {
@fastdivision
fastdivision / smartcalcs-zend-http-demo.php
Last active Aug 11, 2016
TaxJar SmartCalcs /v2/taxes with Zend HTTP Client v2.5.3
View smartcalcs-zend-http-demo.php
<?php
require __DIR__ . '/vendor/autoload.php';
use Zend\Http\Client;
use Zend\Json\Json;
$apiKey = 'YOUR API KEY';
$apiUrl = 'https://api.taxjar.com/v2/taxes';
$client = new Client($apiUrl);
View smartcalcs-php-client-demo.php
<?php
require __DIR__ . '/vendor/autoload.php';
$taxjar = TaxJar\Client::withApiKey('YOUR API TOKEN');
$order_taxes = $taxjar->taxForOrder([
'from_country' => 'US',
'from_zip' => '07001',
'from_state' => 'NJ',
'to_country' => 'US',
@fastdivision
fastdivision / fade.styl
Last active Jan 4, 2016
ng-view / ui-view Fade Animation with ng-animate
View fade.styl
[ui-view]
position absolute
.fade
fadeSpeed = 333ms
-webkit-transition all fadeSpeed ease-in-out
-moz-transition all fadeSpeed ease-in-out
-o-transition all fadeSpeed ease-in-out
transition all fadeSpeed ease-in-out
opacity 1
@fastdivision
fastdivision / Gruntfile.js
Last active Jan 2, 2016
Yeoman Angular 0.7.1 Gruntfile with Divshot.io Integration
View Gruntfile.js
// Generated on 2014-01-09 using generator-angular 0.6.0
'use strict';
// # Globbing
// for performance reasons we're only matching one level down:
// 'test/spec/{,*/}*.js'
// use this if you want to recursively match all subfolders:
// 'test/spec/**/*.js'
module.exports = function (grunt) {
@fastdivision
fastdivision / tweets.js
Last active Dec 27, 2015
NodeJS Twitter API v1.1 Proxy
View tweets.js
var util = require('util'),
express = require('express'),
twitter = require('mtwitter'),
nconf = require('nconf'),
cache = require('memory-cache');
var port = process.env.PORT || 5000
app = express();
You can’t perform that action at this time.