Skip to content

Instantly share code, notes, and snippets.

View rodrigobarona's full-sized avatar
🏠
Working from home

Rodrigo Barona rodrigobarona

🏠
Working from home
View GitHub Profile
@daaku
daaku / facebook-sample.php
Created February 9, 2011 06:18
A simple Facebook PHP example.
<?php
/**
* A simple Facebook PHP example.
*
* - This is not a "Facebook SDK".
* - This example uses Curl, Hash, JSON, Session extensions.
* - This does not use the JavaScript SDK, nor the cookie set by it.
* - This works with Canvas, Page Tabs with IFrames, the Registration Plugin
* and with any other flow which uses the signed_request.
@vitalyrotari
vitalyrotari / touch.js
Last active July 15, 2025 10:39
jQuery Touch Gestures
jQuery Touch Gestures ported from QUOjs
@see http://quojs.tapquo.com/
Version 1.1
-- @add singleTap event
-- @fix doubleTap event
-- @fix hold event
@gr2m
gr2m / account_dreamcode.js
Last active May 7, 2022 08:22
Imagine the typical backend tasks for user authentication would exist right in the browser. How would the code look like? This is what I came up with. Forks & comments much appreciated! #nobackend #dreamcode
// sign up
account.signUp('[email protected]', 'secret');
// sign in
account.signIn('[email protected]', 'secret');
// sign in via oauth
account.signInWith('twitter');
// sign out
@gr2m
gr2m / store.dreamcode.js
Last active February 23, 2020 00:03
Imagine saving and finding user data would work right in the browser, persistent and synchronised. How would the code look like? This is what I came up with. Forks & comments much appreciated! #nobackend #dreamcode
// add a new object
var type = 'note';
var attributes = {color: 'red'};
store.add(type, attributes)
.done(function (newObject) {});
.fail(function (error) {});
// update an existing object
var type = 'note';
var id = 'abc4567';
@rx
rx / zurb-ink-650.css
Last active February 6, 2016 11:02
Zurb Ink converted to 650px wide.
/**********************************************
* Ink v1.0.5 - Copyright 2013 ZURB Inc *
**********************************************/
/* Client-specific Styles & Reset */
#outlook a {
padding: 0;
}
@rodrigobarona
rodrigobarona / amc.sh
Last active October 1, 2015 21:31
Filebot AMC for Plex / XBMC / Kodi
#!/bin/bash
/usr/local/bin/filebot -script fn:amc --output "/Volumes/MediaCenter/" --log-file "/Volumes/MediaCenter/amc.log" --def subtitles=es --action move --conflict override -non-strict --def music=y artwork=y "ut_dir=$TR_TORRENT_DIR/$TR_TORRENT_NAME" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME"
@stefanoverna
stefanoverna / dato.config.js
Last active March 13, 2023 05:22
Simple backup of DatoCMS content
// First option:
// This will dump every content of a DatoCMS space in the "backup" directory
// To be used with the `dato dump` command (see https://docs.datocms.com/other/basic-usage.html)
module.exports = (dato, root, i18n) => {
i18n.availableLocales.forEach(locale => {
root.directory(`backup/${locale}`, localeDir => {
dato.itemTypes.forEach(itemType => {
localeDir.createDataFile(
`${itemType.apiKey}.json`,
@svarlamov
svarlamov / typeform-countries-list.txt
Last active May 10, 2024 22:44
Typeform Global Countries List (Dropdown, Multiple Choice, Legal)
United States
United Kingdom
China
Canada
United Arab Emirates
Australia
Andorra
Afghanistan
Antigua and Barbuda
Anguilla
Thank you for helping me build better applications. As a design engineer, I have specific preferences for how I like to work. Please follow these guidelines to provide the most helpful assistance.
## Technology Stack
- Next.js 15+ with App Router
- TypeScript (strict mode)
- shadcn/ui components
- Tailwind CSS
## Code Style Preferences
- Please use TypeScript with proper typing - avoid `any` types when possible