Skip to content

lianghua1987/javascript-playground

Repository files navigation

Javascript Playground

E-Commerce (Express JS)

Get Started

To run application: npm run dev ecomm.png cart.png set-cookie.png

Troubleshoot

invalid value in custom validator - express-validator/express-validator#619

Movie Fight (Vanilla JS)

Get Started

Movie comparison using OMDb API To run application:

  • Create env.js under current folder with below format:
    const OMDB_API_KEY = "YOUR_API_KEY";
    export default OMDB_API_KEY;
  • Open application using browser preview.png test.png

Message sharing (Vanilla JS)

Get Started

Base64 is used to do the "encryption". To run application, open in browser index.html
To deploy to server, run npx now
See deployed: https://message-sharing-4abdkmh7z-hualiang987-gmailcom.vercel.app/ (Powered by https://vercel.com/) home.png encrypted.png decrypted.png

Testing framework (NodeJS - CLI)

Get Started

npm link
export FORCE_COLOR=true # To set up coloring (Git Bash on PC)
tme

preview.png

Knowledge Concepts

Notorious This

  • Did you define the function with an arrow function? - White console.log(this) on the first valid line about the arrow function. Value of this in the arrow function will be equal to that console log
  • Did you call 'bind', 'call', 'apply' on the function when you invoked it? - 'this' is equal to the first argument of 'bind', 'call', 'apply'
  • All other cases - 'this' is equal to whatever is to the left of the '.' in the method call

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published