mkdir <directory-name>
mkdir hello-world
import { keyStores, Near, utils, WalletConnection } from "near-api-js"; |
There is some coding in this discussion. Feel free to write them in a REPL or in the comments below. | |
How is an object different from an array? | |
How does const work with objects? | |
Explain the difference between bracket syntax and dot syntax. Give an example of something that works with bracket syntax but not dot syntax. Give an example of something that works with dot syntax but not bracket syntax. | |
What are computed properties? Write an example code. | |
What is the difference between Object.keys and Object.entries? Write example code using both of them. | |
How do we get only the values of an object? |
There is some coding in this discussion. Feel free to write them in a REPL or in the comments below.
Answer the following questions with your group:
Answer the following questions with your group:
1- What is passport-google-oauth20
?
2- Why do we use cookieParser
and encryptCookieNodeMiddleware
?
3- How do you let Express app use cookie middlewares (cookieParser, encryptCookieNodeMiddleware) with secret key for handling encryption of cookies *(answer might require code snippets)?
4- How to let your Express app use a middleware function that sends 401 (When not authenticated) error response code for auth errors and 500 (other errors) *(answer might require code snippets)?