misc scripts
This commit is contained in:
11
dev/docker deploy.md
Normal file
11
dev/docker deploy.md
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# Step 1: Build the Docker Image
|
||||||
|
docker build -t my-next-app .
|
||||||
|
# Step 2: Save the Docker Image
|
||||||
|
docker save my-next-app > my-next-app.tar
|
||||||
|
# Step 3: Transfer the Image to the Production Server
|
||||||
|
scp my-next-app.tar user@your-server-ip:/path/to/directory
|
||||||
|
# Step 4: Load the Image on the Production Server
|
||||||
|
ssh user@your-server-ip
|
||||||
|
docker load < my-next-app.tar
|
||||||
|
# Step 5: Run the Docker Container
|
||||||
|
docker run -d -p 80:3000 my-next-app
|
54
dev/node react.md
Normal file
54
dev/node react.md
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
copy
|
||||||
|
|
||||||
|
# npm remove excessive package dependencies
|
||||||
|
# 1.Use Dependency Analysis Tools
|
||||||
|
npm install -g depcheck
|
||||||
|
depcheck
|
||||||
|
# or
|
||||||
|
npm install -g npm-check
|
||||||
|
npm-check
|
||||||
|
|
||||||
|
# 2.Bundle Size Analysis:
|
||||||
|
npm install --save-dev webpack-bundle-analyzer
|
||||||
|
# edit webpack to push BundleAnalyzerPlugin to config.plugins
|
||||||
|
# run #> ANALYZE=true npm run build
|
||||||
|
|
||||||
|
npm uninstall yargs-parser
|
||||||
|
|
||||||
|
yargs-parser
|
||||||
|
Unused dependencies
|
||||||
|
* @date-io/date-fns
|
||||||
|
* @mui/icons-material
|
||||||
|
* @react-pdf/renderer
|
||||||
|
* docx
|
||||||
|
* docx-templates
|
||||||
|
* docxtemplater
|
||||||
|
* excel4node
|
||||||
|
* fs
|
||||||
|
* gapi
|
||||||
|
* gapi-script
|
||||||
|
* html-to-docx
|
||||||
|
* module-alias
|
||||||
|
* node-excel-export
|
||||||
|
* nodemailer-smtp-transport
|
||||||
|
* prisma-binding
|
||||||
|
* react-cookies
|
||||||
|
* react-file-reader
|
||||||
|
* react-hook-form
|
||||||
|
* react-router-dom
|
||||||
|
* react-table
|
||||||
|
* sqlite3
|
||||||
|
* xml-js
|
||||||
|
Unused devDependencies
|
||||||
|
* @types/react-table
|
||||||
|
* autoprefixer
|
||||||
|
* postcss
|
||||||
|
* typescript
|
||||||
|
Missing dependencies
|
||||||
|
* @fullcalendar/core: ./styles/calendar.scss
|
||||||
|
* @fullcalendar/daygrid: ./styles/calendar.scss
|
||||||
|
* @fullcalendar/timegrid: ./styles/calendar.scss
|
||||||
|
* google-auth-library: ./src/helpers/calendar.js
|
||||||
|
* open: ./src/helpers/calendar.js
|
||||||
|
* pages: ./pages/dash.tsx
|
||||||
|
* src: ./pages/cart/publishers/import.tsx
|
Reference in New Issue
Block a user