1
0
Эх сурвалжийг харах

Upgrade nodejs version 16 to 20

CareyWong 9 сар өмнө
parent
commit
7e8b4e5935
6 өөрчлөгдсөн 646 нэмэгдсэн , 604 устгасан
  1. 3 2
      .eslintrc.js
  2. 4 3
      .github/workflows/build.yml
  3. 1 1
      Dockerfile
  4. 13 9
      package.json
  5. 5 4
      vue.config.js
  6. 620 585
      yarn.lock

+ 3 - 2
.eslintrc.js

@@ -10,9 +10,10 @@ module.exports = {
   rules: {
     'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
     'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
-    'semi': 0
+    'semi': 0,
+    'vue/multi-word-component-names': 'off'
   },
   parserOptions: {
-    parser: 'babel-eslint'
+    parser: '@babel/eslint-parser'
   }
 }

+ 4 - 3
.github/workflows/build.yml

@@ -2,7 +2,7 @@ name: Build
 
 on:
   push:
-    branches: [ master ]
+    branches: [ master, dev ]
 
 jobs:
 
@@ -12,7 +12,7 @@ jobs:
 
     strategy:
       matrix:
-        node-version: [16.x]
+        node-version: [20.x]
 
     steps:
     - uses: actions/checkout@v2
@@ -26,8 +26,9 @@ jobs:
       run: |
         yarn install
         yarn build
+
     - name: Upload
-      uses: actions/upload-artifact@v1
+      uses: actions/upload-artifact@v4
       with:
         name: dist
         path: dist/

+ 1 - 1
Dockerfile

@@ -1,5 +1,5 @@
 # ---- Dependencies ----
-FROM node:16-alpine AS build
+FROM node:20-alpine AS build
 WORKDIR /app
 COPY . .
 RUN yarn install

+ 13 - 9
package.json

@@ -2,6 +2,9 @@
   "name": "sub-web",
   "version": "0.1.0",
   "private": true,
+  "engines": {
+    "node": ">=20.0.0"
+  },
   "scripts": {
     "serve": "vue-cli-service serve",
     "build": "vue-cli-service build",
@@ -19,19 +22,20 @@
     "vue-router": "^3.5.1"
   },
   "devDependencies": {
-    "@vue/cli-plugin-babel": "^4.5.13",
-    "@vue/cli-plugin-eslint": "^4.5.13",
-    "@vue/cli-plugin-pwa": "~4.5.0",
-    "@vue/cli-plugin-router": "^4.5.13",
-    "@vue/cli-service": "^4.5.13",
-    "babel-eslint": "^10.0.3",
+    "@babel/core": "^7.26.0",
+    "@babel/eslint-parser": "^7.25.9",
+    "@vue/cli-plugin-babel": "5",
+    "@vue/cli-plugin-eslint": "5",
+    "@vue/cli-plugin-pwa": "5",
+    "@vue/cli-plugin-router": "5",
+    "@vue/cli-service": "5",
     "babel-plugin-component": "^1.1.1",
     "babel-plugin-import": "^1.13.3",
-    "eslint": "^5.16.0",
-    "eslint-plugin-vue": "^5.0.0",
+    "eslint": "8.56.0",
+    "eslint-plugin-vue": "9.17.0",
     "sass": "^1.43.4",
     "sass-loader": "^8.0.0",
-    "svg-sprite-loader": "^4.2.1",
+    "svg-sprite-loader": "6.0.11",
     "vue-particles": "^1.0.9",
     "vue-template-compiler": "^2.6.10"
   }

+ 5 - 4
vue.config.js

@@ -37,10 +37,11 @@ module.exports = {
       // https://developers.google.com/web/tools/workbox/modules/workbox-webpack-plugin
       skipWaiting: true,
       clientsClaim: true,
-      importWorkboxFrom: 'local',
-      importsDirectory: 'js',
+      importScripts: [
+        'https://storage.googleapis.com/workbox-cdn/releases/6.4.1/workbox-sw.js'
+      ],
       navigateFallback: '/',
-      navigateFallbackBlacklist: [/\/api\//]
+      navigateFallbackDenylist: [/\/api\//]
     }
   }
-};
+};

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 620 - 585
yarn.lock


Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно