This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* eslint-disable @typescript-eslint/no-unsafe-call */ | |
/* eslint-disable @typescript-eslint/no-unsafe-assignment */ | |
/* eslint-disable @typescript-eslint/no-unsafe-member-access */ | |
import { NextApiRequest, NextApiResponse } from 'next'; | |
import type Stripe from 'stripe'; | |
import { prisma } from '~/server/db'; | |
import { stripe } from '~/utils/stripe'; | |
import { buffer } from 'micro'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*------------------------------------------ | |
Responsive Grid Media Queries - 1280, 1024, 768, 480 | |
1280-1024 - desktop (default grid) | |
1024-768 - tablet landscape | |
768-480 - tablet | |
480-less - phone landscape & smaller | |
--------------------------------------------*/ | |
@media all and (min-width: 1024px) and (max-width: 1280px) { } | |
@media all and (min-width: 768px) and (max-width: 1024px) { } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This needs entered in Shopify's GraphQL app to change visibility of metafield. | |
mutation ($input: MetafieldStorefrontVisibilityInput!) { | |
metafieldStorefrontVisibilityCreate(input: $input) { | |
metafieldStorefrontVisibility { | |
id | |
} | |
userErrors { | |
field | |
message |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Sometimes you need to move your existing git repository | |
# to a new remote repository (/new remote origin). | |
# Here are a simple and quick steps that does exactly this. | |
# | |
# Let's assume we call "old repo" the repository you wish | |
# to move, and "new repo" the one you wish to move to. | |
# | |
### Step 1. Make sure you have a local copy of all "old repo" | |
### branches and tags. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Actions | |
**/ | |
import { | |
VEHICLE_MAKE_CHANGED, | |
VEHICLE_MODEL_CHANGED, | |
VEHICLE_ADD_REQUEST, | |
VEHICLE_ADD_SUCCESS, | |
VEHICLE_ADD_ERROR | |
} from './types'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Joi from 'joi'; | |
import routePrerequisites from './routePrerequisites'; | |
// Data schemas | |
import {CheckoutSerializer} from './serializers'; | |
// API endpoint handlers | |
import { | |
CheckoutsHandler, | |
CheckoutIdHandler | |
} from './handlers'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {Decorators as DBDecorators} from '../../core/db'; | |
import {PermissionDenied} from '../../core/errors'; | |
import {Cart} from '../carts/models'; | |
import {CartSerializer} from '../carts/serializers'; | |
import {User} from '../users/models'; | |
import log from './logging'; | |
const tables = { | |
Checkout: 'Checkouts' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Joi from 'joi'; | |
import {sanitizeEmailAddress} from '../../core/email'; | |
import {ErrorName} from '../../core/errors'; | |
import {BadRequest} from '../../core/responses'; | |
import {hasKeys} from '../../core/utils'; | |
import {Cart} from '../carts/models'; | |
import log from './logging'; | |
import {Checkout} from './models'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
renderScene(route, navigator) { | |
if (route && route.component) { | |
let Component = route.component; | |
return ( | |
<Component navigator={navigator} route={route} /> | |
) | |
} | |
switch (this.state.currentRoute) { | |
case 'LOGIN_STATE_LOGOUT': |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//var GUEST_URL = process.env['DOCKER_HOST'].substring(0, guestPortIndex); | |
console.log(proxy.createServer({ | |
target : 'http://192.168.99.100', | |
ws: true | |
}).listen(2376)); |
NewerOlder