Skip to content

Instantly share code, notes, and snippets.

Faddah Wolf faddah

Block or report user

Report or block faddah

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
View build.gradle
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
jcenter()
maven {
url 'https://maven.google.com/'
name 'Google'
}
google()
@faddah
faddah / index.html
Created Mar 14, 2018
My Video Search & Play Project from Stephen Grider's "Modern React With Redux" Udemy Course
View index.html
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="/style/style.css">
<link rel="stylesheet" href="https://cdn.rawgit.com/twbs/bootstrap/48938155eb24b4ccdde09426066869504c6dab3c/dist/css/bootstrap.min.css">
<script src="https://maps.googleapis.com/maps/api/js"></script>
</head>
@faddah
faddah / App.js
Created Jun 18, 2017
My version of Jason Brown's React Native progress bar from his video tutorial
View App.js
import React, { Component } from 'react';
import { AppRegistry, StyleSheet, Text, View, Animated } from "react-native";
class ProgressBar extends Component {
componentWillMount() {
this.animation = new Animated.Value(this.props.progress);
}
componentDidUpdate(prevProps, prevState) {
@faddah
faddah / bash.txt
Created Mar 31, 2017
JavaScript Console from my Angular.JS 1.6.4 Weather SPA.
View bash.txt
angular.js:14525 Error: [$sce:insecurl] http://errors.angularjs.org/1.6.4/$sce/insecurl?p0=https%3A%2F%2Fapi.openweathermap.org%2Fdata%2F2.5%2Fforecast%2Fdaily
at https://code.angularjs.org/1.6.4/angular.min.js:6:425
at getTrusted (https://code.angularjs.org/1.6.4/angular.min.js:155:411)
at Object.c.(anonymous function) [as getTrustedResourceUrl] (https://code.angularjs.org/1.6.4/angular.min.js:157:175)
at p (https://code.angularjs.org/1.6.4/angular.min.js:102:451)
at https://code.angularjs.org/1.6.4/angular.min.js:101:207
at https://code.angularjs.org/1.6.4/angular.min.js:134:467
at m.$digest (https://code.angularjs.org/1.6.4/angular.min.js:145:417)
at b.$apply (https://code.angularjs.org/1.6.4/angular.min.js:149:113)
at HTMLFormElement.<anonymous> (https://code.angularjs.org/1.6.4/angular.min.js:284:239)
View jquery_easing_example.js
$('.top-btn').click(function(e) {
const top = $('#top')[0];
$(this).animate(
{
scrollTop: top
}, 600, 'swing', () => {console.log("going back up!")});
});
@faddah
faddah / script.js
Created Dec 13, 2016
JavaScript trying to add key/value pair with Map.property.set()
View script.js
document.querySelector('#outcome5').innerHTML = inventors.sort((a, b) => {
const lastPersonAge = a.passed - a.year;
const nextPersonAge = b.passed - b.year;
a.set(age, lastPersonAge);
b.set(age, nextPersonAge);
return nextPersonAge > lastPersonAge ? 1 : -1;
}).map(inventor => ` ${inventor.first} ${inventor.last} — age: ${inventor.passed - inventor.year}`);
View index.html
<div id="calc-app" class="loading">Loading</div>
<div class="clear"></div>
@faddah
faddah / deploy.rb
Created Oct 5, 2016
Capistrano *.rb file for a WordPress deployment
View deploy.rb
# The project repo name. (one word: no spaces, dashes, or underscores)
set :application, "wp_capistrano_martian" #FIXME
# Legacy from porting from drupal, best to just leave this as "default"
set :domains, ["default"]
# Set the repository type and location to deploy from.
set :scm, :git
set :repository, "git@github.com:faddah/wp_capistrano_martian.git" #FIXME
# set :scm, :subversion
@faddah
faddah / Capfile
Last active Oct 5, 2016
Capfile for deploying a WordPress install
View Capfile
# TODO: Cap db:push should support rollback or backup in some way
# TODO: Better handling of database creation - perhaps make the deploy user a database admin?
load 'deploy' if respond_to?(:namespace) # cap2 differentiator
Dir['vendor/plugins/*/recipes/*.rb'].each { |plugin| load(plugin) }
load 'config/deploy.rb'
require 'capistrano/ext/multistage'
namespace :deploy do
@faddah
faddah / page-sidebar-left.php
Created Aug 17, 2016
my page-sidebar-left.php file from zac gordon's treehouse course on wordpress theme development
View page-sidebar-left.php
<?php
/*
Template Name: Left Sidebar
*/
<section class="two-column row no-max pad">
<div class="small-12 columns">
<div class="row">
You can’t perform that action at this time.