We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0bf339b commit 4ef0782Copy full SHA for 4ef0782
src/main.js
@@ -21,12 +21,16 @@ import * as filters from './filters' // global filters
21
22
/**
23
* If you don't want to use mock-server
24
- * you want to use mockjs for request interception
25
- * you can execute:
+ * you want to use MockJs for mock api
+ * you can execute: mockXHR()
26
*
27
- * import { mockXHR } from '../mock'
28
- * mockXHR()
+ * Currently MockJs will be used in the production environment,
+ * please remove it before going online! ! !
29
*/
30
+import { mockXHR } from '../mock'
31
+if (process.env.NODE_ENV === 'production') {
32
+ mockXHR()
33
+}
34
35
Vue.use(Element, {
36
size: Cookies.get('size') || 'medium' // set element-ui default size
0 commit comments