Skip to content

Instantly share code, notes, and snippets.

View f1lander's full-sized avatar
🦎
picheteando

ethdax f1lander

🦎
picheteando
View GitHub Profile
@f1lander
f1lander / blocked-addressed.json
Last active October 11, 2023 20:21
list of blocked addressed
{
"addresses": [
"0xFe7cBb9cCd3057589eeBcb915c9d959A822C4b7B",
"0x06C5034A2049abC450b8A891d02017CeE1D398B0"
]
}

0x04f601d61b672dc81fd1d071f5e4bd5337737a67849d4123775730080d024799

import fs from 'fs';
import path from 'path';
import dotenv from 'dotenv';
import * as Figma from 'figma-api';
dotenv.config();
//#region constants
const FIGMA_FILE_KEY = 'L4oZwYVUdpgacZtwipGaYe';
@f1lander
f1lander / ExampleUsage.tsx
Created February 1, 2022 23:09 — forked from matthewsimo/ExampleUsage.tsx
Help Storybook properly handle the relevant Stitches variants & props
import type * as Stitches from "@stitches/react";
import { modifyVariantsForStory } from "../../../.storybook/type-utils";
import { styled } from "../../stitches.config";
const Example = styles("div", {
// ...
});
export default Example;
const { S3 } = require('aws-sdk')
jest.mock('aws-sdk');
// see the previous gist file I created here
// https://gist.github.com/f1lander/287cf20fb8dbfcce24a5c3e867346788
import s3Utils from './s3-utils';
// I set this for debug
jest.setTimeout(45000);
import AWS from 'aws-sdk';
// set your process env
const {
S3_BUCKET,
STAGE } = process.env;
const endpoint = 'http://localhost:4572';
// set your config look
// https://docs.aws.amazon.com/sdk-for-javascript/v2/developer-guide/s3-example-configuring-buckets.html
@f1lander
f1lander / find-pairs.js
Last active October 10, 2019 21:53
Find count of pairs of HackerRank code challenge
const ar = [10, 20, 20, 10, 10, 30, 50, 10, 20];
const getPairs = (n, ar) => {
let pairs = 0, i = 0;
ar.sort((a, b) => a - b);
while (i < n) {
const count = ar.filter(item => item === ar[i]).length;
if (count >= 2) {
/**
Example Code for developer position application
Write some code, that will flatten an array of arbitrarily nested arrays of integers into a flat array of integers. e.g. [[1,2,[3]],4] -> [1,2,3,4].
For this code I'll use JS (es6) running in NodeJS v11
Instructions:
const xtreme_math = require("../../ceutek/deunitek/xtreme-math");
const math = new xtreme_math(3);
console.log(math.square); // resultado: 9.
const xtreme_math = require("../../ceutek/deunitek/xtreme-math");
const math = new xtreme_math(3);
console.log(math.square); // resultado: 9.