From 8e3d6381ad0e7cb9a75aa7675d06bee5e934b997 Mon Sep 17 00:00:00 2001 From: Lee EC Date: Thu, 22 Aug 2019 16:18:48 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=9B=B4=E6=96=B0=20xview=20=E4=B8=8A?= =?UTF-8?q?=E6=8A=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dist/index.html | 4 ++-- dist/index_demo.html | 4 ++-- info.json | 6 +++--- src/index.js | 12 ++++++++++-- 4 files changed, 17 insertions(+), 9 deletions(-) diff --git a/dist/index.html b/dist/index.html index 5009b3b..29bd865 100644 --- a/dist/index.html +++ b/dist/index.html @@ -6,12 +6,12 @@ demo - +
- + diff --git a/dist/index_demo.html b/dist/index_demo.html index 6c4ae12..df4d70d 100644 --- a/dist/index_demo.html +++ b/dist/index_demo.html @@ -8,7 +8,7 @@ - +
@@ -17,5 +17,5 @@ - + diff --git a/info.json b/info.json index f7f3e47..3b72385 100755 --- a/info.json +++ b/info.json @@ -5,9 +5,9 @@ "title": "little_thing", "ambName": "运动墨迹", "github": "https://github.com/o2team-ambient/little_thing", - "demoSnippet": "\n
\n ", - "controlUrl": "//storage.jd.com/ambient/control-little_thing.js?t=1565786831000", - "configUrl": "//storage.jd.com/ambient/config-little_thing.js?t=1565786831000", + "demoSnippet": "\n
\n ", + "controlUrl": "//storage.jd.com/ambient/control-little_thing.js?t=1566461916000", + "configUrl": "//storage.jd.com/ambient/config-little_thing.js?t=1566461916000", "placeholderImg": "//storage.jd.com/ambient/little_thing_placeholder.png?t=1554256256000", "gifImg": "//storage.jd.com/ambient/little_thing_motion.gif?t=1553866143000", "spriteImg": "//storage.jd.com/ambient/little_thing_sprite.png?t=1554256256000" diff --git a/src/index.js b/src/index.js index 678acd6..da33991 100755 --- a/src/index.js +++ b/src/index.js @@ -20,6 +20,14 @@ try { console.log(e) } -Report.init({}) -Report.processPV() +const handleReport = () => { + Report.init({}) + Report.processPV() +} + +if (typeof window.XView === 'undefined') { + handleReport() +} else { + window.handleReport = handleReport +} \ No newline at end of file