일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
31 |
- 기준
- node.js
- HTML
- JavaScript
- CLASS
- express.js
- API
- Redux
- hardhat
- middleware
- CSS
- Props
- error
- web
- SSR
- evm
- concept
- Interface
- Ethereum
- bitcoin
- graphQL
- REACT
- solidity
- typeScript
- blockchain
- useState
- built in object
- tailwindcss
- nextJS
- 삶
- Today
- Total
목록Frontend (231)
ReasonJun
If typescript cannot infer the type and need to do type annotation 1. In case of unilaterally returning any type const json = '{"x": 1, "y": 2}'; const coordinates = JSON.parse(json); console.log(coordinates); 2. If you declare a variable first and initialize it later => In this case, it is inferred as any. let greeting greeting = 'hello' // let greeting: any 3. When the value to be assigned to ..

The void type is used to represent functions that do not return a value. This is typically used for functions that have side effects, such as logging or printing to the console. For example: function logMessage(message: string): void { console.log(message); } const result = logMessage("Hello, world!"); // The result of this function is void The never type is used to represent functions that neve..

In TypeScript, an enum is a special "class" that represents a group of constants (unchangeable variables). Enums come in two flavors string and numeric. enum means enumerated type. An enum names a set of values and makes them available. Here we can utilize an enum to use a set called PrintMedia with a friendly name instead of a hard-to-remember number. Each PrintMedia enumerated is zero-based by..
The fs module, the path module, and the gray-matter module are all popular JavaScript modules that are used for working with files and directories. The fs module provides a set of functions for reading, writing, and manipulating files and directories. It is a core module in the Node.js platform, so it is always available when you are working with Node.js. The path module provides a set of functi..

Error When installing next.js as follows, an error like the following picture occurred. Cause & Solution: https://www.totaltypescript.com/react-refers-to-a-umd-global Explained: 'React' refers to a UMD global Find out why this error occurs and learn how to fix it. www.totaltypescript.com Personal thought & solution However, personally, I just followed the method provided by next.js, but I didn't..

getServerSideProps is a function that is used to fetch data from the server in Next.js. It is called on every request and the data that it returns is used to render the page. This is useful for pages that need to fetch data that changes often, such as user data or product information. getServerSideProps is a function that takes two arguments: req is the HTTP request object. res is the HTTP respo..