Skip to content

Instantly share code, notes, and snippets.

Avatar
:octocat:
👨🏻‍💻

Jerome Ramos mouthzipper

:octocat:
👨🏻‍💻
View GitHub Profile
@mouthzipper
mouthzipper / react-app-s3-sync.sh
Created Feb 28, 2020 — forked from kevindice/react-app-s3-sync.sh
A shell script for uploading a React app build to S3 + CloudFront for deployment
View react-app-s3-sync.sh
#!/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 \
@mouthzipper
mouthzipper / s3Sync.sh
Created Feb 28, 2020 — forked from kellyrmilligan/s3Sync.sh
Sync files to s3 and set cache control headers
View s3Sync.sh
#!/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 / HOC.js
Created Jan 8, 2019 — forked from Restuta/HOC.js
React HOC (Higher Order Component) Example
View HOC.js
/* 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 {
View acs-kubernetes MacOS
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
View react-native ios ats
<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>localhost</key>
<dict>
<key>NSTemporaryExceptionAllowsInsecureHTTPSLoads</key>
<false/>
<key>NSIncludesSubdomains</key>
<true/>
@mouthzipper
mouthzipper / README.md
Last active Nov 19, 2018 — forked from marc-rutkowski/README.md
react-storybook with react-boilerplate (content of the .storybook/ directory)
View README.md

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.

View gist:040d550277cb185024a8df09eeb0b77d
### 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-Template.md
Created May 8, 2017 — forked from PurpleBooth/README-Template.md
A template to make good README.md
View README-Template.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

@mouthzipper
mouthzipper / nginx.conf
Created Sep 26, 2016 — forked from calebwoods/nginx.conf
Sample Nginx config for deployment of Angular.js app
View nginx.conf
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 / AngularStrap hover popover contents
Created Mar 9, 2016 — forked from bstruthers/AngularStrap hover popover contents
Extend AngularStrap popover so the contents can interact with the mouse
View AngularStrap hover popover contents
/**
* 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