Skip to content

Instantly share code, notes, and snippets.

View mouthzipper's full-sized avatar
:octocat:
👨🏻‍💻

Jerome Ramos mouthzipper

:octocat:
👨🏻‍💻
View GitHub Profile
@mouthzipper
mouthzipper / AngularStrap hover popover contents
Created March 9, 2016 03:29 — forked from bstruthers/AngularStrap hover popover contents
Extend AngularStrap popover so the contents can interact with the mouse
/**
* Popover Directive. Wraps the AngularStrap popover and
* 1) Allows the popover to stay open when hovering / focusing the contents.
* If the popover was only triggered by 'hover' or 'focus', it closes as soon
* as the mouse leaves or focus is lost on the triggering element.
*
* 2) Lazy initializes the popover until it's needed. This reduces the
* amount of scope.
*
* 3) When the popover closes, cleans up the AngularStrap popover memory leak
@mouthzipper
mouthzipper / nginx.conf
Created September 26, 2016 07:25 — forked from calebwoods/nginx.conf
Sample Nginx config for deployment of Angular.js app
server { listen 80;
server_name example.com;
access_log /var/log/example.com/nginx.access.log;
error_log /var/log/example.com/nginx.error.log;
root /var/www/apps/example.com/public;
charset utf-8;
location / {
rewrite ^ https://$host$request_uri? permanent;
}
@mouthzipper
mouthzipper / README-Template.md
Created May 8, 2017 08:02 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

### Keybase proof
I hereby claim:
* I am mouthzipper on github.
* I am mouthzipper (https://keybase.io/mouthzipper) on keybase.
* I have a public key ASCcewIrGd8BZPleN3p3j1jfkzm5eGQutZwsKowNOvzHAQo
To claim this, I am signing this object:
@mouthzipper
mouthzipper / README.md
Last active November 19, 2018 16:34 — forked from marc-rutkowski/README.md
react-storybook with react-boilerplate (content of the .storybook/ directory)

react-storybook with react-boilerplate

Explains how to install and configure react-storybook into a project created from the react-boilerplate setup.

Intro

React-boilerplate (rbp) is a good starting point to create React apps, with a focus on performance, best practices and DX.

The community around the repository is amazing and a constant source of learning.

<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>localhost</key>
<dict>
<key>NSTemporaryExceptionAllowsInsecureHTTPSLoads</key>
<false/>
<key>NSIncludesSubdomains</key>
<true/>
Setup Gofish Package Manager
1. Intall via curl
curl -fsSL https://raw.githubusercontent.com/fishworks/gofish/master/scripts/install.sh | bash
2. Init gofish
gofish init
Install acs-engine using gofish
1. gofish install acs-engine
Install azue-clie via brew
1.Install brew
1. install ruby
@mouthzipper
mouthzipper / HOC.js
Created January 8, 2019 01:28 — forked from Restuta/HOC.js
React HOC (Higher Order Component) Example
/* HOC fundamentally is just a function that accepts a Component and returns a Component:
(component) => {return componentOnSteroids; } or just component => componentOnSteroids;
Let's assume we want to wrap our components in another component that is used for debugging purposes,
it just wraps them in a DIV with "debug class on it".
Below ComponentToDebug is a React component.
*/
//HOC using Class
//it's a function that accepts ComponentToDebug and implicitly returns a Class
let DebugComponent = ComponentToDebug => class extends Component {
@mouthzipper
mouthzipper / s3Sync.sh
Created February 28, 2020 21:33 — forked from kellyrmilligan/s3Sync.sh
Sync files to s3 and set cache control headers
#!/bin/bash
if [[ "$1" != "" ]]; then
S3BUCKETNAME="$1"
else
echo ERROR: Failed to supply S3 bucket name
exit 1
fi
aws s3 sync build s3://$S3BUCKETNAME --delete --cache-control max-age=31536000,public
@mouthzipper
mouthzipper / react-app-s3-sync.sh
Created February 28, 2020 23:00 — forked from kevindice/react-app-s3-sync.sh
A shell script for uploading a React app build to S3 + CloudFront for deployment
#!/bin/bash
S3_BUCKET_NAME=$1
CF_ID=$2
# Sync all files except for service-worker and index
echo "Uploading files to $S3_BUCKET_NAME..."
aws s3 sync build s3://$S3_BUCKET_NAME/ \
--acl public-read \
--exclude service-worker.js \