提交 e3c854da 编写于 作者: D DCloud_LXH

chore: build

上级 ee8b06b9
const xhr = new XMLHttpRequest();
const isProduction = process.env.NODE_ENV === "production"
const isMock = false
import mock from './mock'
......@@ -6,6 +5,7 @@ import mock from './mock'
function ajax(url = '', method = 'get',) {
return new Promise((resolve, reject) => {
if (!url) reject('url 不可为空')
const xhr = new XMLHttpRequest();
xhr.open(method, url);
xhr.onreadystatechange = function () {
if (this.readyState == 4 && this.status == 200) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册