Skip to content

Instantly share code, notes, and snippets.

View AyoAlfonso's full-sized avatar
:octocat:
Building

Ayo Alfonso AyoAlfonso

:octocat:
Building
View GitHub Profile
@AyoAlfonso
AyoAlfonso / media-query.css
Created December 27, 2019 04:59 — forked from gokulkrishh/media-query.css
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
//CSS
@AyoAlfonso
AyoAlfonso / media-query.css
Created December 27, 2019 04:59 — forked from gokulkrishh/media-query.css
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
//CSS
@AyoAlfonso
AyoAlfonso / media-query.css
Created December 27, 2019 04:59 — forked from gokulkrishh/media-query.css
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
//CSS
@AyoAlfonso
AyoAlfonso / sql-mongo_comparison.md
Created December 13, 2019 03:04 — forked from aponxi/sql-mongo_comparison.md
MongoDb Cheat Sheets

SQL to MongoDB Mapping Chart

SQL to MongoDB Mapping Chart

In addition to the charts that follow, you might want to consider the Frequently Asked Questions section for a selection of common questions about MongoDB.

Executables

The following table presents the MySQL/Oracle executables and the corresponding MongoDB executables.

@AyoAlfonso
AyoAlfonso / home-brew-mysql-essential-commands
Created February 14, 2019 12:57 — forked from jasperf/home-brew-mysql-essential-commands
Homebrew Create a MySQL database and user to be used for a WordPress site from the command line with mysql and restart server when you have a socket error or other error #wordpress #mysql #homebrew
//homebrew mysql start
/usr/local/Cellar/mysql/5.6.19/bin/mysql.server restart
//or
mysql.server start
//check for access privileges
mysqlaccess localhost user database
importScripts('https://www.gstatic.com/firebasejs/4.8.1/firebase-app.js');
importScripts('https://www.gstatic.com/firebasejs/4.8.1/firebase-messaging.js');
import messaging from 'config/firebase'
messaging.setBackgroundMessageHandler(function (payload) {
console.log('We Received a background message ', payload);
const notificationTitle = 'New Background Message Title';
const notificationOptions = {
import messaging from 'config/firebase'
export function initializePush() {
messaging
.requestPermission()
.then(() => {
return messaging.getToken();
})
.then(token => {
console.log("FCM Token:", token);
@AyoAlfonso
AyoAlfonso / indexOfCRA.js
Last active December 5, 2018 23:04
Entry point of our Firebase react app
/**
* @description Entry point of our app
*/
const Component = () => (
<Provider store={store}>
<App />
</Provider>
)
@AyoAlfonso
AyoAlfonso / removeElement.js
Created November 25, 2018 18:04
Remove Elements Without Filtering
export const removeElement = (list, id) => {
const removeIndex = list.findIndex(item => item.id === id)
if (removeIndex == -1) {
return list;
/*Return the original array if you cant find the id to delete*/
}
if (removeIndex == 0){
return ...list.slice(1);
}
@AyoAlfonso
AyoAlfonso / gist:e5f39d60a83d5adc4a897919818a9560
Created November 15, 2018 09:38 — forked from digitaljhelms/gist:4287848
Git/GitHub branching standards & conventions

Branching

Quick Legend

Description, Instructions, Notes
Instance Branch