Skip to content

Instantly share code, notes, and snippets.

View diogobeda's full-sized avatar

Diogo Beda diogobeda

View GitHub Profile
@diogobeda
diogobeda / gtm.js
Created October 27, 2023 13:16
gtm troll
// hahaha I'm GTM and I'll just add this to the head of the page
// thus breaking all the javascript on the page
// because "I'm GTM and I'm the most important thing on the page"
document.addEventListener("click", e => {
e.preventDefault();
});
products = [
{
name: "Caneca Moustache ",
sku: "CA1UN20SM01",
quantity: "1",
price: "180",
description:
" Caneca modelada à mão com muito amor. Fala sério, olha a textura desse bigode ♡ ",
},
{
const flatten = (input) => input.reduce((acc, item) => {
const flattenedItem = item instanceof Array
? flatten(item)
: item;
return acc.concat(flattenedItem);
}, []);
@diogobeda
diogobeda / qweqwwq.js
Created September 7, 2018 12:38
my second gist
function myGist() {
console.log('hhahaha')
}

asdsadasdasdasdas

asdsadasdasd

qweqeqweq

Verifying that +diogobeda is my blockchain ID. https://onename.com/diogobeda
@diogobeda
diogobeda / robot.js
Created December 18, 2012 19:34
Baculo
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.ahead(100);