Browse Source

Add ESLint support and Google Sign-In integration

0es 4 months ago
parent
commit
dce5ec98ff
7 changed files with 869 additions and 14 deletions
  1. 6 0
      .vscode/settings.json
  2. 13 2
      app/app.vue
  3. 11 0
      ecosystem.config.cjs
  4. 6 0
      eslint.config.mjs
  5. 9 1
      nuxt.config.ts
  6. 10 2
      package.json
  7. 814 9
      yarn.lock

+ 6 - 0
.vscode/settings.json

@@ -0,0 +1,6 @@
+{
+  "editor.formatOnSave": false,
+  "editor.codeActionsOnSave": {
+    "source.fixAll.eslint": "explicit"
+  },
+}

+ 13 - 2
app/app.vue

@@ -1,6 +1,17 @@
+<script setup lang="ts">
+import GoogleSignInPlugin from 'vue3-google-signin'
+
+const { vueApp } = useNuxtApp()
+
+vueApp.use(GoogleSignInPlugin, {
+  clientId: '111172807665-6pqfdrdtepq2hbqcr0a05tahis6lr4fc.apps.googleusercontent.com',
+})
+</script>
+
 <template>
   <div>
-    <NuxtRouteAnnouncer />
-    <NuxtWelcome />
+    <NuxtLayout>
+      <NuxtPage />
+    </NuxtLayout>
   </div>
 </template>

+ 11 - 0
ecosystem.config.cjs

@@ -0,0 +1,11 @@
+module.exports = {
+  apps: [
+    {
+      name: 'Lanu Web',
+      port: '3000',
+      exec_mode: 'cluster',
+      instances: 'max',
+      script: './.output/server/index.mjs',
+    },
+  ],
+}

+ 6 - 0
eslint.config.mjs

@@ -0,0 +1,6 @@
+// @ts-check
+import withNuxt from './.nuxt/eslint.config.mjs'
+
+export default withNuxt(
+  // Your custom configs here
+)

+ 9 - 1
nuxt.config.ts

@@ -1,5 +1,13 @@
 // https://nuxt.com/docs/api/configuration/nuxt-config
 export default defineNuxtConfig({
+  modules: [
+    '@nuxt/eslint',
+  ],
+  devtools: { enabled: true },
   compatibilityDate: '2025-07-15',
-  devtools: { enabled: true }
+  eslint: {
+    config: {
+      stylistic: true,
+    },
+  },
 })

+ 10 - 2
package.json

@@ -7,11 +7,19 @@
     "dev": "nuxt dev",
     "generate": "nuxt generate",
     "preview": "nuxt preview",
-    "postinstall": "nuxt prepare"
+    "postinstall": "nuxt prepare",
+    "lint": "eslint .",
+    "lint:fix": "eslint . --fix"
   },
   "dependencies": {
+    "@nuxt/eslint": "1.10.0",
+    "eslint": "^9.0.0",
     "nuxt": "^4.2.1",
     "vue": "^3.5.24",
-    "vue-router": "^4.6.3"
+    "vue-router": "^4.6.3",
+    "vue3-google-signin": "^2.1.1"
+  },
+  "devDependencies": {
+    "typescript": "^5.9.3"
   }
 }

File diff suppressed because it is too large
+ 814 - 9
yarn.lock


Some files were not shown because too many files changed in this diff