Skip to content

Commit cac3160

Browse files
Vue.config.performance can't work
https://jsfiddle.net/50wL7mdz/94913/
1 parent 4746256 commit cac3160

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

Diff for: src/core/util/perf.js

+6-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import config from '../config'
12
import { inBrowser } from './env'
23

34
export let mark
@@ -16,9 +17,11 @@ if (process.env.NODE_ENV !== 'production') {
1617
mark = tag => perf.mark(tag)
1718
measure = (name, startTag, endTag) => {
1819
perf.measure(name, startTag, endTag)
19-
perf.clearMarks(startTag)
20-
perf.clearMarks(endTag)
21-
perf.clearMeasures(name)
20+
if (!config.performance) {
21+
perf.clearMarks(startTag)
22+
perf.clearMarks(endTag)
23+
perf.clearMeasures(name)
24+
}
2225
}
2326
}
2427
}

0 commit comments

Comments
 (0)