Skip to content

Instantly share code, notes, and snippets.

View stevecastaneda's full-sized avatar

Steve Castaneda stevecastaneda

View GitHub Profile
@dabit3
dabit3 / connectweb3wallet.js
Created December 1, 2021 16:19
Connecting a web3 wallet
import { ethers } from 'ethers'
import Web3Modal from 'web3modal'
import WalletConnectProvider from '@walletconnect/web3-provider'
async function getWeb3Modal() {
const web3Modal = new Web3Modal({
network: 'mainnet',
cacheProvider: false,
providerOptions: {
walletconnect: {
@federicofazzeri
federicofazzeri / .babelrc
Last active February 7, 2022 14:45
Node Express-based REST API (CRUD) using Firebase cloud Functions and FireStore cloud database + Babel config (The current Node version running in Cloud Functions is 6.10)
{
"presets": [
["env", {
"targets": {
"node": "6.10"
}
}]
]
}
@patpohler
patpohler / Big List of Real Estate APIs.md
Last active April 25, 2024 16:22
Evolving list of Real Estate APIs by Category

Big List of Real Estate APIs

Listings / Property Data

####Rets Rabbit http://www.retsrabbit.com

Rets Rabbit removes the nightmare of importing thousands of real estate listings and photos from RETS or ListHub and gives you an easy to use import and Web API server so you can focus on building your listing search powered website or app.

@ryanb
ryanb / issues_with_modules.md
Created November 29, 2012 22:38
Points on how modules can make code difficult to read.

My issues with Modules

In researching topics for RailsCasts I often read code in Rails and other gems. This is a great exercise to do. Not only will you pick up some coding tips, but it can help you better understand what makes code readable.

A common practice to organize code in gems is to divide it into modules. When this is done extensively I find it becomes very difficult to read. Before I explain further, a quick detour on instance_eval.

You can find instance_eval used in many DSLs: from routes to state machines. Here's an example from Thinking Sphinx.

class Article < ActiveRecord::Base