Skip to content

Instantly share code, notes, and snippets.

View YO-SC's full-sized avatar

Ysael Sáez YO-SC

View GitHub Profile
@hiaux0
hiaux0 / file-mime-types.ts
Last active April 23, 2024 20:43
Typescript Enum for file mime types
// https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types
enum MimeTypes {
".aac" = "audio/aac",
".abw" = "application/x-abiword",
".arc" = "application/x-freearc",
".avi" = "video/x-msvideo",
".azw" = "application/vnd.amazon.ebook",
".bin" = "application/octet-stream",
".bmp" = "image/bmp",
@vktr
vktr / rule.js
Created February 10, 2018 18:54
Add Stripe Customer Id to Auth0 via custom rule
function (user, context, callback) {
user.app_metadata = user.app_metadata || {};
if ('stripe_customer_id' in user.app_metadata) {
context.idToken['https://example.com/stripe_customer_id'] = user.app_metadata.stripe_customer_id;
return callback(null, user, context);
}
var stripe = require('stripe')('sk_....');
var customer = {
@RhythmShahriar
RhythmShahriar / captcha.css
Last active June 17, 2023 14:05
Simple Captcha for bootstrap form
/**-------------------------------------------------
* Simple Captcha System
* @package Code Snippets
* @link http://rhythmshahriar.com/codes/
* @author Rhythm Shahriar <rhy@rhythmshahriar.com>
* @link http://rhythmshahriar.com
* @copyright Copyright © 2017, Rhythm Shahriar
---------------------------------------------------*/
body {
background-color: #2d2d2d;
@ericelliott
ericelliott / .gitignore
Created November 15, 2016 19:51
Sample Node project .gitignore
node_modules
build
npm-debug.log
.env
.DS_Store
@hemantajax
hemantajax / media-queries.css
Last active March 2, 2024 07:05
Very useful media queries snippets
/* Smartphones (portrait and landscape) ----------- */
@media only screen
and (min-device-width : 320px)
and (max-device-width : 480px) {
/* Styles */
}
/* Smartphones (landscape) ----------- */
@media only screen
and (min-width : 321px) {