Skip to content

Instantly share code, notes, and snippets.

View popcorn245's full-sized avatar
👻

Bobby ^_^ popcorn245

👻
View GitHub Profile
function heyThere(message = "My default message") {
alert(message);
}
heyThere("Custom Message");
heyThere();
@popcorn245
popcorn245 / DadeMobile.d.ts
Created February 17, 2019 22:14
DadeMobile.d.ts
{
setApiKey: (apiKey: string) => void;
setApiBaseURL: (apiBaseUrl: string) => void;
/**
* After initialization, the next step is to stage a payment. The payment amount can be set when staging a payment, or after a payment has already been staged, depending on your workflow. If a payment was previously staged but not confirmed, then it will be resumed.
*/
stagePayment: (params: {
/**
* Unique identifer for your user making the payment.
*/
@popcorn245
popcorn245 / auth.ts
Created July 26, 2018 17:44
Firebase Auth Service Wrapper
/**
* @module Services
*/
// import { Facebook, FacebookLoginResponse } from '@ionic-native/facebook';
// import { TwitterConnect } from '@ionic-native/twitter-connect';
import firebase from 'firebase/app';
import 'firebase/auth';
export class AuthService {
ion-page {
top: 0;
right: 0;
bottom: 0;
left: 0;
position: absolute;
z-index: 0;
display: flex;
@popcorn245
popcorn245 / app-home.tsx
Created January 10, 2018 18:59
Baking with StencilJS
import { Component } from '@stencil/core';
@Component({
tag: 'app-home',
styleUrl: 'app-home.scss'
})
export class AppHome {
render() {
@popcorn245
popcorn245 / import.tsx
Created September 25, 2017 18:39
Stencil with Import
import { Component, Prop } from '@stencil/core';
import Ajax from 'ajax-promise-es6';
@Component({
tag: 'ft-irma',
styleUrl: 'ft-irma.scss'
})
export class FtIrma {
render() {
@popcorn245
popcorn245 / dabblet.css
Last active February 16, 2017 04:43
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
@popcorn245
popcorn245 / CellProviders.json
Created April 8, 2016 18:11
An array of cell providers with name and domain for text messaging via e-mail.
[
{ 'name': '3 River Wireless', 'domain': 'sms.3rivers.net' },
{ 'name': 'ACS Wireless', 'domain': 'paging.acswireless.com' },
{ 'name': 'Alltel', 'domain': 'message.alltel.com' },
{ 'name': 'AT&T', 'domain': 'txt.att.net' },
{ 'name': 'Blue Sky Frog', 'domain': 'blueskyfrog.com' },
{ 'name': 'Bluegrass Cellular', 'domain': 'sms.bluecell.com' },
{ 'name': 'Boost Mobile', 'domain': 'myboostmobile.com' },
{ 'name': 'BPL Mobile', 'domain': 'bplmobile.com' },
{ 'name': 'Carolina West Wireless', 'domain': 'cwwsms.com' },
@popcorn245
popcorn245 / hue_colors.md
Last active December 10, 2023 03:10
XY Color Conversion

FROM HUE DESIGN DOCS

https://github.com/PhilipsHue/PhilipsHueSDK-iOS-OSX/blob/00187a3db88dedd640f5ddfa8a474458dff4e1db/ApplicationDesignNotes/RGB%20to%20xy%20Color%20conversion.md

#Conversion between RGB and xy in the CIE 1931 colorspace for hue The conversion between RGB and xy in the CIE 1931 colorspace is not something Philips invented, but we have an optimized conversion for our different light types, like hue bulbs and LivingColors. It is important to differentiate between the various light types, because they do not all support the same color gamut. For example, the hue bulbs are very good at showing nice whites, while the LivingColors are generally a bit better at colors, like green and cyan.

@popcorn245
popcorn245 / Rest.js
Created November 5, 2015 16:04
My awesome rest services with promises written in plain old JS.
angular.module('AppName').service('Rest', function($http, $q, $httpParamSerializer){
this.get(rUrl, rParams) {
if (!rParams) {
rParams = false;
} else {
rParams = this.$httpParamSerializer(rParams);
}
var deferred = this.$q.defer();
this.$http.get(rUrl, rParams, {
headers: {