Ad

Tuesday, October 18, 2022

React UI, UI UX, Reactstrap React Bootstrap

React UI MATERIAL 

Install

yarn add @material-ui/icons

Reactstrap

FORMS. Controlled Forms. Uncontrolled Forms. 

Columns, grid

Monday, September 5, 2022

Sunday, September 4, 2022

Every day data science

Real estate data science example

 home price / median income ratio. "Historically, an average house in the U.S. cost around 5 times the yearly household income. During the housing bubble of 2006 the ratio exceeded 7 - in other words, an average single family house in the United States cost more than 7 times the U.S. median annual household income." If this ratio is too high it could be a signal of housing bubble. 

https://www.longtermtrends.net/home-price-median-annual-income-ratio/

Thursday, August 25, 2022

Cool NFTs Q3 2022

Warning: Please do your own research. We cannot verify the code, team or tokenomics of the below mention projects. Please do your own research. Crypto and NFTs are highly speculative and risky. Improper use of smart contracts, signing message can compromise your entire wallet/ portfolio / digital assets. Please only use test wallets, new wallets and test tokens. 

John's skeleton's

https://twitter.com/jjjjjjjjjjohn/status/1559591140797677569

Tezos NFT https://tezos-mandala.art/

Trending concept:  token gated store, community, club e.g. token gated shopify store front.  a solana store is being designed in miami. The space already has a virtual render. 

Tiffany is making CryptoPunk pendants with fine jewelry. It is still very unaffordable. To make the jewelry you will need to own the punk, which is included in the hefty price tag!  The floor price of punks is not trivial

We haven't heard about too many successful NFTs launching on Coinbase except for Bill Murray's. It includes variation of many of his cool acting career milestones and climate change and political beliefs The Bill Murray 1000 collection offers 100 story NFTs containing anecdotes, observations, advice, memories, Murray-isms, and more. https://nft.coinbase.com/drops/bill-murray-1000 including The Life Aquatic with Steve Zissou



Wednesday, August 24, 2022

Crypto wallet remove permission, remove connection. Disconnect wallet from trusted sites.

 Do your own research. Please read our disclaimer. Crypto security is tricky. This method is seen on the internet is not guaranteed to work.  Just doing this disconnect wallet with trusted site is usually not enough to ensure security. 


Magic Ethen / @MagicEden.

***There seems to be a widespread SOL exploit at play that's draining wallets throughout the ecosystem

Here's what you can do right now to best protect yourself

1. Go to >Settings on your @phantom

2. >Trusted Apps wallet 

3. >Revoke Permissions for any suspicious links

7:08 AM Aug 3, 2022

Read the full conversation on Twitter

Monday, August 15, 2022

Wit.ai Natural Language Processing (NLP) - Facebook Developer 2021

 Wit.ai

The most important goal for wit.ai in 2020-2021 (as seen in promotions in hackathons and developer jams) include:

multi modal applications using wit and Portal (not yet available to all developers), conversation model, conversation design, fitness, wellness.

Wit.ai can be the NLP layer of your app. It can make your web app and mobile app voice enabled, and smart with AI. 

For authentication the wit.ai api uses a auth bearer token, which you must include in your API call. 

Integration between Wit.ai and Facebook Messenger is readily available, natural and easy. It is frequently seen in hackathons. 

Future and exciting projects using wit.ai: wit AI for daily usage,  fitness, wellness seems to be active areas that Facebook is promoting during hackathons

Security wise it is unclear if your data goes through encryption. It also looks like Facebook will have access to the data (refer to term of service). You assume some ownership of the data, for example you can download the training data. Disclaimer: we are not lawyers, and we are unsure about the logistics of term of usage and the legal part of wit.ai


Wit.ai hackathons : fitness, 

Past hackathon winners: Robin accountant which can set a budget and track expense. 


Build intent handler. Code intent handler

NLP Wit https://medium.com/wit-ai/inside-wit-ais-first-ever-developer-jam-7da37b181088

Sunday, August 14, 2022

Developer tools dev tools, developer efficiency hacks

Plugins :  sublime plugin for sublime editor, extensions for vscode. 

VSCode (VS Code) basics:

Drag file to text editing panel to preview, edit and write code. 

View > Layout > Two columns to view files side-by-side

Another reason to use Visual Studio Code, VS Code will display a little color swatch right next the hexadecimal value of CSS colors. 

Live server, live preview, hot loading functionality available for web development. 

Visual Studio Code can be used for JavaScript, Python, Deep Learning. Visual Studio Code VS Code extension code runner, run multiple languages including javascript. (node.js must be installed). Click on code runner, select language javascript. 

Click hold terminal output tab drag it to the right, to dock it there, 


Typing code on iOS: Did you know you can long hold symbols/keys for more programming friendly syntax? For example, long hold the quote key to type ' instead of ".  When typing in notepad, the double quote is stylized, not valid programming script syntax. 

Build a portfolio, publish to Github, and or using Github page. 

Node.js app basics

  • node.js is command line runtime for javascript based on v8
  • Node.js, it's a JavaScript runtime built on Chrome's V8 JavaScript engine.  —> Node.js provided new host objects in addition to native JavaScript objects (source codeacdemy). Same engine. Node non-blocking queue fast efficient, less, don’t do one by one can handle it as it comes, send it as it is ready. Blocking analogy (the opposite: 
  •  
  • npm install 
    • install all dependencies in package.json
    • npm install adds the node_modules folder if it doesn't already exists and add files to the folder
    • If using npm i generates package.lock, you might seen yarn.lock if using yarn
  • Rename any env.example file to .env if that file contains the environment variable and authentications that you would like to use
  • npm start 
    • executes the startup script

tags: web dev, webdev, 

Getting started with Moralis

Moralis is a powerful Web3 framework for building decentralized apps (dapps). Moralis supports many chains both mainnets and testnets. That's impressive! Ethereum (and other EVM compatible chains and tokens), polygon, binance smart and now avalanche and fantom!! Rad! You can use moralis to build web3 apps quickly. By the way, Moralis has super good documentation, this blog post is just my personal notes. You really don't need it. But you can read it like a summary, initial walk through, guided tour. The moralis documentation is excellente. 


Web3 dev platform. Great for creating dapps. Moralis API handles all the common tasks.  Moralis projects are organized under email accounts, then each project has its own server (select net to be mainnet testnet    ). Once a server is created you will get the API info: server URL app id and secrets. 

01 In moralis dashboard initialize a server with your desired blockchain. Use testnet for tutorials and education purpose. Grab the server API key. Launch Moralis Server Initialize SDK in your app.

02 in your app.js or main.js first import moralis then initialize your moralis variables

03 All user info instantly in Moralis Server Database Tokens, MATIC, NFT Balances and Transaction once user logs in. 

The server will automatically go to sleep after a period of non use. 

Web3 APIs by Moralis : inspect the API endpoints in the admin panel. You can preview sokme of the functionalities and see what values are received as a part of the request. Moralis APIs : can retrieve all transactions in EVM compatible chains that are supported, also Solana. Retrieve all tokens. 

It also provides some building blocks and really good looking UI for building DEX (this functionality is limited in the USA but is super useful in places where DEX's are allowed). Ivan talks about the potentially to charge referral fees. Do your own research, know your regulations. This is not advice, not professional advice, not production/commercial used. At your own risk. Crypto is very risky.

On Moralis API page/dashboard, we can see all the GET and POST methods available. 

Example Solana API on 

Solana API
GET /dateToBlock Gets the closest block of the provided date
GET /block/(block_number_or_hash} Gets block contents by block hash
GET {address}/logs Gets address logs
GET /block/block_number_or_hash)/nft/transfers Gets NFT transfers by bomber or block hash ?
GET /transaction/(transaction_hash} Get transaction details by transaction hash

POST
POST/address)/eventsaddress)/function
Gets events by topic …

Moralis functionalities. Moralis can get price of token. Smart contract events automatically synced to moralis database. 

Core functionality of a decentralized app [pro, paid members only] What does a dapp need? Core functionalities of a dApp. dapp functionality and API. [pro] https://ml.learn-to-code.co/skillView.html?skill=6s5vjOJHbl4mq0QyejOD


Moralis new release

What’s Moralis nitro
Supposedly according the newsletter. Coming soon. Not yet available
🚀 10x faster user sync
🚀 10x faster smart contract sync
🚀 10x more robust dApps

Moralis has a JavaScript course for beginners to JavaScript programming and web3. But it has a price tag $2000. The founder Ivan founded the course, and he is an awesome guy. He tweets about this Js course, Moralis, and he seems to be a crypto bull.

Moralis SDK

Moralis JavaScript SDK: v2.  "This Node.js library will feature integrations for new Moralis 2.0 products, starting with our Auth API, EVM API, and Solana API.

Moralis Solana API

balance
getSPL
getNFT
getPortfolio gets all three at the same time

It's possible to use Moralis and Serverless cloud functions to create complex web3 apps. 

A word on going live: WARNING and reminder our tutorials, codes and contents are not for production use. While you can go live, please use only testnet, throw-away wallet, wallet that contains no real tokens. 

When developing on web3, you can test using a test node in one of the ethereum test networks, or a ganache local node, or a free hosted node provided by cloud flare. Blockchain, web3 and crypto applications must be thoroughly tested, using the industry best practice, and being audited and monitored regularly. 

Hackers often target these applications. A reminder: warning our code base does not support production usage, does not support live, commercial usage. Our codes have not being tested in live/production/deployed environments. They cannot be used on mainnet. We are not liable for any costs, damages, losses. Please read our full disclaimer, terms of usage. 

You have worked with different chains such as mainnet, testnet, or Ganache (Ganache is your own local development chain).

It must be hosted locally on your computer or publicly on a server like Netlify.


The easiest method is with the "Live Server" extension for Visual Studio Code.

You can also use Python's built-in web server.

Moralis connects to your front-end app. It's like firebase for web3 service. Moralis calls itself firebase for blockchain / web3 apps. It gives you the backend, so you can focus on building the application logic and the front end. Actually Moralis even offers pre-build UI that takes care of the front end. For its own backend, Moralis uses MongoDB, which gives develoeprs familiar commands and API. Moralis makes use of MongoDB. An example of high quality pre-build UI is  ethereum-boilerplate-NFT-Marketplace https://github.com/ethereum-boilerplate/ethereum-nft-marketplace-boilerplate

Use Moralis with React:
https://github.com/MoralisWeb3/react-moralis
Can use react components and hooks in Moralis React apps. 

Moralis auth use Moralis to log in

Login User
Moralis.Web3.authenticate().then(function (user) { console.log(user.get('ethAddress'))

Connecting Moralis with WalletConnect
To use walletconnect with Moralis, you will have to use a community module. Walletconnect can be connected with TrustWallet. Note this is an older module, it’s a bit inconvenient to work with. Just add the Wallet provider parameter as a provider. There’s a moralis video about it. 
Moralis.web3.enable({provider: 'walletconnect'});
user = await Moralis.Web3.authenticate({provider: 'walletconnect' });
web3= await Moralis.Web3.enable({provider: 'walletconnect' });

Stacks : serverless dapp + web3.js + moralis 

Moralis Versions

Previously Moralis 1.0
"Ivan on Tech 01/17/2022 MORALIS SDK 1.0 IS OUT!! Very important upgrade to the SDK that will take Moralis to the next level This will allow us to move faster, add more features faster, add more chains faster, add more wallets faster 1) Ethers support by default 2) Will allow many many more auth methods future"
3) Allows Solana support to be added soon
4) Modular refactoring that enables more extensions in the Breaking changes: There are some minor breaking changes - Migration"

Now it is Moralis 2.0


Tuesday, July 26, 2022

Debugging error RecursionError: maximum recursion depth exceeded

"RecursionError: maximum recursion depth exceeded"

Issue the maximum recursion depth is reached. The maxinum depth is 1000 in python.

solution 01

 "The default is 1000 levels deep and you can change that using the setrecursionlimit function in the sys module."

https://stackoverflow.com/questions/3289430/maximum-level-of-recursion-in-python

solution 02 

Use an iterative approach. 





Sunday, July 24, 2022

Tesla Charging Tips Shared By Tesla - How to Charge Tesla Quickly, Efficiently

Tesla: "

  • Find the fastest Supercharger Filter by three bolts in navigation
  • Navigate to the Supercharger Battery will precondition for faster charging
  • Arrive with 20% battery or less Maximize charge rate
  • Leave space between cars
  • Neighboring stalls may share power Move your car after charging
  • Idle fees may apply 

" - per Tesla released note

Saturday, July 23, 2022

Go Pro reelready stabilization

 Go Pro 9 10 has build in video stabilization, called hypersmooth 2.0 (in-camera stabilization). GoPro sells a separate software called Reelready GO for $99+ bucks which will take in gyroscope data, to stabilize post-production. The GoPro player can also play stabilized video if the footage comes from a gopro camera with gyro data https://community.gopro.com/s/article/GoPro-Player-ReelSteady-Compatible-Presets

Solana Developer Resources + Getting Started with Solana

Solana is a layer 1 blockchain. 

Why Solana? Fast, cheap, can be robust https://youtu.be/TTdcs7EYfcw




 Current event:

- Solana build during bear market

https://twitter.com/solana/status/1546513148114599939


Solana Summer Camp Hackathon

Twitter space talk

https://twitter.com/i/spaces/1YqKDqqQyeDGV

Prizes : payments ~50K, grants, no need to give up equity (?),  Prizes are grants, no equity necessary to participate. 

Summer camp. coworking, hacker houses around the world. For example the San Francisco Summer Camp is located at a co-working space called SPACES near the pier 39 occasion front. 


Getting started with Solana

What is Rust [flash card] 👇🏼

https://ml.learn-to-code.co/skillView.html?skill=LEhDxIfgayEmO0Ny3yve


Community

Developer lifestyle : really love the solana designs, and color palette, just so good with the new gaming aesthetics, reminds me of cool clubs and gaming conferences. Fun fact, trivia there's even a Solana beer : https://decrypt.co/108376/solana-beer-degods-okay-bears-nfts-summer-shandy There's also the Solana IRL Store in Miami and NYC https://decrypt.co/106088/solana-spaces-irl-store-web3-embassy-new-york

 

Get involved Solana Ambassador


Past price

solana SOL $165 December 13, 2021


Getting Start with Rust

Rust is a system language like C C++ and GO. It has included memory management. C++ requires DIY.


Task: Create a Rust project

$ cargo init


Definition: Cargo is the package manager for Rust


Task: run the main program in Rust. Source file has main function

$ cargo run


Main function is always the first function that will be executed when running rust. If one changes function to a different name will get error.


Task: Hello World with Rust. 


pub fn hello(){

println!("Hello World!");

}


Task: import hello module. Mod is the keyword for module. 


mod hello;

fn main(){

hello::hello();

}


Task: use :: syntax to call function in a module

module_name::function_name


Task : view startup scripts Scroll down to the bottom of package.json

"scripts":{

"start": "nodemon app.js",

"serve": "node",

}


Task: serialize, deserialize data between code and byte code. Encode and decode. 

Discord

Grape (GRAPE), a solution for validating users on Solana. "Create, Reward & Secure any online community by harnessing the power of Solana" - Coingecko


Solana Mobile 

Solana mobile stack in progress, becoming the chain that mobile developers think about (Packy McCormick

Why is the Solana leadership excited about Solana Mobile? All in one Solana platform - comparable to the emergence of super apps like WeChat. Rough transcription:  "WeChat moment for crypto. Super app for everything in crypto. Solana mobile. Crypto can track an address interact with u, know the entire history."

Speaker, currently interaction is mostly on desktop, need the wechat moment for crypto - super app), 


solana in person todo

learning resource

Seen on twitter “The Solana Development Course on @soldevapp is soo good! Great work and thank you to @jamesrp13 and the other contributors! 

Potential Solana courses: (we have not had a chance to try or test these courses) Solana course https://soldev.app/course

Moralis supports Solana. Current two types of development tools are available SDK and REST API. Here are some of the API endpoints https://moralis.io/solana-api/ 

Solana web3 javascript SDK API

Solana Documentation : Web3 JavaScript API What is Solana-Web3.js? https://docs.solana.com/developing/clients/javascript-api

injected web3 window.solana .

Community size: discord member August 2021 ~ 133,000.

What's Squid Prize? Solana contribution Prize https://twitter.com/solana/status/1555647981281476614

Solana Supported Wallets

Solana ecosystems, apps, wallets [public]
https://ml.learn-to-code.co/skillView.html?skill=rCPnrSqeZ2x4pnBUA0Iw

Warning : only use test wallet, test tokens. Never use real tokens for  experiments. Never to real tokens for development. Always do your own research. Applies to all tech, cryptos and more. 



If using web extension, browser extension need to install before using. 

Flash card for our pro paid members.
Solana Wallet Adapter [pro]
https://ml.learn-to-code.co/skillView.html?skill=Pfc3e6qzu1MKc0v4SsLx

Thursday, July 21, 2022

 


Alchemy jsonrpc, eth_getBalance request result is 0x429d069189e000

Startup Tool - Square Payroll, Square Team, and Square Payment Review

We have been using Square Payroll for our startup. It takes care of filing and forms. Which is pretty amazing. You are probably familiar with Square payment POS point of sale system. Did you know it also offer free online shop and URLs (ecommerce portal like shopify), tracks inventory, . It also offers payroll, time card, team time tracker via the Square Team app, clock in clock out is easy. Payroll supports contractors and full time employees, handles direct deposit. We haven't tried it yet but these benefits and HR options are available : external HR as a service, benefits such as shopping for healthcare, retirement plan. So cool. It's a joy to not deal with these HR pain points. That makes a startup founder happy. 

Startup Engineering 101

 draft in progress

Traction : active user revenue

Product Market Fit

What Problem are you trying to solve?
Figuring out Sources of Motivation

Communications, Culture and Hustling

Minimize email time and meeting time (that's why so many startups prefer Slack, the conversation is immediate and transient). Every email should add value, else, just delete it. Replace long meetings with a morning standup meeting to set goals, remove obstacles and make sure each person can start the day right. Do this as long as you can, till you are too big. 

Common Failures

When user education requirement is high. It takes a long time for users to understand your project and the use case of your product.

Users don't have the problems often. 

YCombinator

YCombinator how to apply https://www.ycombinator.com/howtoapply/

Top Things to do on Twitch

 You can watch more than live streaming of games on twitch. Twitch can be a sports platform, community interaction, watch games, learn coding, live coding.

  • Things you can watch on twitch: competitive chess games. Live coding by pro developers.
  • Use OBS for live streaming, and use an iPad as a second monitor. 
  • Developer and conferences on Twitch: e.g. Neo4j Graph database

Monday, July 11, 2022

Firebase Basics 2022

Firebase is an app development platform, owned and supported by Google. Firebase helps developers launch serverless database. 

These are the enterprise users that use Firebase.



Firebase extension: Firebase plugin for external APIs such as MailChimp, Stripe. 

Firebase Extension Event: released 2022, add additional custom logic, code on 3rd party API. Event based, more customization on Firebase Extension. Additional Custom logic. Example firebase function, firebase extension event code snippet. 


Firebase offerings : screenshot from firebase developer event by google

Firebase security rule testing. Example pseudo code :  if request id == resource id can view, edit. Basically means if the creator of the object is equal to the requester of the object, go ahead and let them view and edit. Use Firebase emulator to develop and test. 

Sunday, July 10, 2022

Excel for Data Analysts

Automation (自动化操作): automate data analysis in excel 

Columns: ranges from A B C D ... to AA AB AC...

Dashboard : did you know you can create interactive, complex dashboard in excel. There youtube tutorials how to do this, and do statistical analysis on your data.

Data Analysis (数据分析): 

Data Format:

Dialog box : additional small controls, menu, modals popped up after selecting a menu item.

Pivot table: Pivot table row column, value, filter is what not to show

Ribbon : the control menu where all the copy paste, formatting buttons are.

Advanced functions in Excel:
Financial functions, solver, historic trend line, trend line fitting, correlated movements.

Pro tips:
It's possible to select data cells and name those cells. See an example here : 
This is called named range.



Saturday, July 9, 2022

Compare Turbotax Products Infographics

 This infographics is from amazon.com. This is not financial advice. Just find it helpful comparing different products of turbotax. As an entrepreneur, I often have to make decisions about which Turbotax version to choose. 

For my home business with schedule C + investments I often have to choose the best one - Turbotax home and business. Previously when I had rental no business, I just had to use premier. Again this is not financial advice. 


React UI, UI UX, Reactstrap React Bootstrap

React UI MATERIAL  Install yarn add @material-ui/icons Reactstrap FORMS. Controlled Forms. Uncontrolled Forms.  Columns, grid