Skip to content

Instantly share code, notes, and snippets.

View chadoh's full-sized avatar
🌲

Chad Ostrowski chadoh

🌲
View GitHub Profile

NEAR Studio

  • can we use Glitch instead?
  • why does "open near studio" button on https://nearprotocol.com/get-started/ open in a new tab instead of current?
  • when studio first opens, I feel a little overwhelmed. Contributing factors:
    • small font size
    • needing to pick an example – which one is the best to start with??
    • i'd rather have a super simple hello-world-type app open immediately
  • this is my complete intro to the NEAR stack – it doesn't seem like it's structured like a tutorial, though. All of a sudden it's asking me to make choices about wallet integrations vs smart contracts. If I don't even know what these things are yet, I'll probably just close this page

Hey! I'm Chad Ostrowski! On the Internet I go by chadoh. It's not the best nickname, but we go way back, this nickname and me.

Why you're here

Hopefully you're reading this page to learn:

  • What motivates me
  • What I like and dislike from the teams I work with
  • How to work well with me
@chadoh
chadoh / ebay-scraper.js
Last active January 16, 2020 13:28
node script to search ebay for a search term and print items + prices to your terminal
const jsdom = require("jsdom")
const { JSDOM } = jsdom
const fetch = require('node-fetch');
const newItemRegex = new RegExp('<span class="LIGHT_HIGHLIGHT">New Listing</span>')
const scrapeEbaySearchResults = dom => console.log(
Array.from(
dom.querySelectorAll('ul.srp-results li.s-item')
).map(li => ({

Product workflow proposal

  1. someone has product/feature idea (probably Javi or Yalda, but could be anyone)

  2. record this idea in the product GitHub repo as an Epic

  3. Tech Lead goes through these raw ideas and adds rough ballpark pessimistic estimates

  4. Product Team sorts estimated epics into sprints

Humanity's challenges grow more global in scope. Climate change. Mass migration. Technological disruption. Pandemics.

Yet our ability to coordinate effective responses seems insufficient.

  • Corporations have neither transparent, participatory governance, nor incentive alignment with humanity and the ecosystems that support us.
  • Nation states trigger tribal identities and isolationism, leave populations feeling dissaffected, and suffer capture by monied interests and autocratic leaders.
  • Non-profits and NGOs struggle toward effective operation. Cooperative and democratic workplaces have sparked interest in only a small portion of the economy.
  • The open-source ethos remains a tactic employed by few industries; open source projects lack the tools to coordinate and fund contributions from a workforce sufficient to their ambitions.

How can humanity coordinate to solve global challenges?

@chadoh
chadoh / output.txt
Created September 20, 2019 20:20
`npm i` deleting address-book directory
oe update-client-to-0.8-experimental * • g s
M apps/planning-suite-kit/package.json
M apps/shared/test-helpers/ganache-cli.sh
M package.json
oe update-client-to-0.8-experimental * • npm i
npm WARN lifecycle The node binary used for scripts is /usr/local/opt/asdf/shims/node but npm is using /usr/local/Cellar/asdf/0.5.1/installs/nodejs/10.11.0/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.
> planning-suite-monorepo@ postinstall /Users/chadoh/code/a/oe
> npm run bootstrap
$ npm run start:dev
npm WARN lifecycle The node binary used for scripts is /usr/local/opt/asdf/shims/node but npm is using /usr/local/Cellar/asdf/0.5.1/installs/nodejs/10.11.0/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.
> planning-suite-monorepo@ start:dev /Users/chadoh/code/a/oe
> DEV=true apps/shared/test-helpers/ganache-cli.sh
Starting our own testrpc instance at port 8545
npm WARN lifecycle The node binary used for scripts is /usr/local/opt/asdf/shims/node but npm is using /usr/local/Cellar/asdf/0.5.1/installs/nodejs/10.11.0/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.
> planning-suite-monorepo@ frontend /Users/chadoh/code/a/oe
@chadoh
chadoh / search.ts
Last active September 17, 2019 19:36
const ordinalize = (cond1: boolean, cond2: boolean): -1 | 0 | 1 => {
if (cond1 && !cond2) return -1
if (!cond1 && cond2) return 1
return 0
}
const sortResults = (query: string, unsortedList: string[]): string[] => {
const exact = new RegExp(`^${query}$`)
const startsWith = new RegExp(`^${query}`)
const aWordMatchesIn = item => item.split(' ').reduce(
↓ Start a local Ethereum network [skipped]
→ Connected to the provided Ethereum network
✔ Check IPFS
❯ Publish app to APM
✔ Applying version bump (major)
❯ Deploy contract
⠋ Compile contracts
Deploy 'PlanningDummy' to network
Generate deployment artifacts
Determine contract address for version
diff --git a/apps/dot-voting/app/App.js b/apps/dot-voting/app/App.js
index b5176932..609e588f 100644
--- a/apps/dot-voting/app/App.js
+++ b/apps/dot-voting/app/App.js
@@ -9,10 +9,41 @@ import { IdentityProvider } from '../../../shared/identity'
import Decisions from './Decisions'
import emptyStatePng from './assets/voting-empty-state.png'
+import { ETHER_TOKEN_FAKE_ADDRESS } from './utils/token-utils'
+const appState = {