Skip to content

Instantly share code, notes, and snippets.

View sergical's full-sized avatar

Sergiy Dybskiy sergical

View GitHub Profile
View filepicker.js
multiple: false,
maxFiles: 1,
var fileTotal = 0;
sergical / accouts.js
Created February 5, 2015 17:42
View accouts.js
Accounts.onCreateUser(function(options, user) {
//misc stuff
Invites.remove({_id: options.profile.invite});
//this is what i need to be doing?
user.isNew = true;
sergical / methods.js
Created February 11, 2015 23:35
This is my method in Meteor when a user tries to pay the invoice. I want to be able to set up a custom email receipt but I don't know where to start.
View methods.js
payInvoice: function (token, transfer) {
// TODO: add checks
console.log('=== Pay Invoive ===');
console.log(JSON.stringify(transfer, null, 2));
var Stripe = StripeAPI(transfer.invoice.stripe.accessToken);
View passwordValidator.js
function isPasswordValid(input) {
if (!hasUppercase(input)) {
console.log('Password needs a capital letter');
if (!hasLowercase(input)) {
console.log('Password needs a lowercase letter');
if (!isLongEnough(input)) {
console.log('Password needs to be longer');
sergical / eb-fix.js
Last active July 6, 2017 19:19
Elastic Beanstalk fix to set client side Meteor settings
View eb-fix.js
if (Meteor.isProduction) {
// public settings that need to be exposed to the client can be added here
const publicEnvs = {
// Your client settings go here
Meteor.settings.public = publicEnvs;
__meteor_runtime_config__.PUBLIC_SETTINGS = Meteor.settings.public;
View new-design.css
.NewDesign {
background-color: #f6f6f7;
.NewDesign button.Polaris-Button--primary {
background: #008060;
border-color: #008060;
.NewDesign button[role="gridcell"][aria-selected="true"] {