This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// eslint-disable-next-line @typescript-eslint/ban-ts-comment | |
// @ts-ignore | |
import { useRouter } from "next/router"; | |
import { useEffect, useState } from "react"; | |
import { QueryClient, dehydrate, useQuery } from "@tanstack/react-query"; | |
// import Pagination from "@material-ui/lab/Pagination"; | |
export default function PaginationSSR(props) { | |
const router = useRouter(); | |
const [page, setPage] = useState(parseInt(router.query.page) || 1); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import axios from 'axios'; | |
import fs from 'fs'; | |
const images = ["https://avatars.githubusercontent.com/u/9200214?s=500&v=2"]; | |
(async () => { | |
function getImage(url, index) { | |
try { | |
axios({ | |
method: 'get', | |
url, |
-
Write a JavaScript function that reverse a number.
Example x = 32243; Expected Output : 34223
-
Write a JavaScript function that checks whether a passed string is palindrome or not?
A palindrome is word, phrase, or sequence that reads the same backward as forward, e.g., madam or nurses run.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
watchman watch-del-all && rm -rf node_modules/ && yarn cache clean && yarn install && yarn start -- --reset-cache |
In your command-line run the following commands:
brew doctor
brew update
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# DO NOT RESPOND TO REQUESTS OTHER THAN yourdomain.com | |
server { | |
listen 80 default; | |
server_name _; | |
return 444; | |
} | |
# FILE UPLOADS | |
server { | |
listen 80; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- TechStacks/Language | |
- Javascript | |
- https://github.com/ganqqwerty/123-Essential-JavaScript-Interview-Questions | |
- https://www.toptal.com/javascript/10-most-common-javascript-mistakes | |
- https://www.toptal.com/javascript/interview-questions | |
- https://medium.com/javascript-in-plain-english/js-engine-and-optimization-dac1f7fcb87d | |
- https://www.freecodecamp.org/news/javascript-essentials-why-you-should-know-how-the-engine-works-c2cc0d321553/ | |
- https://github.com/yangshun/front-end-interview-handbook | |
- lexical scoping | |
- React 16 |
https://codeburst.io/how-to-setup-nginx-for-react-a504f38f95ed
cd /etc/nginx/sites-enabled
ln -s ../sites-available/krim.com .
For Sequence of location in nginx: https://stackoverflow.com/questions/5238377/nginx-location-priority
For Nginx location priority: http://nginx.org/en/docs/http/ngx_http_core_module.html#location
NewerOlder