소스 검색

增加测试埋点

xinfeng 5 년 전
부모
커밋
9b20cc3641
2개의 변경된 파일4개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      .nuxtignore
  2. 2 0
      middleware/initialize.js

+ 2 - 1
.nuxtignore

@@ -1 +1,2 @@
-node_modules
+node_modules/*
+.nuxt/*

+ 2 - 0
middleware/initialize.js

@@ -22,6 +22,7 @@ export default function (context) {
     }
     url = proto + "://" + host;
     cookies = req.headers.cookie;
+    console.log("server", req.headers)
   }
   // Client-side
   if (process.client) {
@@ -32,6 +33,7 @@ export default function (context) {
       proto = "https";
     }
     cookies = document.cookie;
+    console.log("client", document.location)
   }
   let groups = {}
   try {