在线观看不卡亚洲电影_亚洲妓女99综合网_91青青青亚洲娱乐在线观看_日韩无码高清综合久久

鍍金池/ 問答/ HTML問答
氕氘氚 回答

你是不是本地開發(fā)打開的頁面?地址是 c://xxxx/index.html 之類的,這樣就算服務器設置了允許跨域也是會出現(xiàn)問題的

陪妳哭 回答

setTimeout(function(){

              var mySwiper = $('#swiper1').swiper({
            loop: true,
            autoplay: 4000, //自動切換的時間間隔(單位ms)        
            speed: 500, //滑動速度:自動滑動開始到結(jié)束的時間(單位ms)        
            autoplayDisableOnInteraction: false, //注意此參數(shù),默認為true        
            observer: true, //修改swiper自己或子元素時,自動初始化swiper        
            observeParents: true, //修改swiper的父元素時,自動初始化swiper        
    });
               },500);

用延時器包一下
或者把初始化swiper的js放到動態(tài)加載圖片的代碼之后

憶當年 回答

text-indent:2em;的需求,干嘛用空格?
非要用實體字符的話,參考下這個

避風港 回答

你現(xiàn)在用的是對對象展開,也就是說你的item應該也是一個對象。

另外 出什么錯?錯誤信息是啥?復現(xiàn)步驟是啥?擠牙膏似的交流是最沒效率的。

兔寶寶 回答

duration Number 否 指定錄音的時長,單位 ms ,如果傳入了合法的 duration ,在到達指定的 duration 后會自動停止錄音,最大值 600000(10 分鐘),默認值 60000(1 分鐘)

裸橙 回答

nodetree 能滿足需求。
使用:

var nodetree = require('nodetree');
nodetree(process.cwd());

輸出類似如下:

├── favicon.ico
├── html
│?? ├── about.html
│?? └── index.html
├── image
│?? ├── github.png
│?? └── robot.png
├── manifest.json
├── script
│?? ├── commonjs
│?? │?? └── printMe.js
│?? └── entryjs
│??     ├── about.js
│??     └── index.js
└── style
    └── index.css
忠妾 回答
voiceObj.pageList[index].showList=!this.data.voiceObj.pageList[index].showList
巴扎嘿 回答

crx后綴改成zip解壓。。。

巴扎嘿 回答

你試著把這個樣式 在inner里放一份看看

兔寶寶 回答

上傳成功之后在回調(diào)方法內(nèi)置空數(shù)據(jù)

若相惜 回答

webpack 3.0以上的版本,熱更新中要去掉hot:true選項并且命令啟動要取消--hot參數(shù)。

你可以試試,雖然你的版本不是3.0以上。

艷骨 回答
      {
        test: /\.css$/,
        include: /node_modules\/antd/,
        use: [
          require.resolve('style-loader'),
          {
            loader: require.resolve('css-loader'),
            options: {
              modules:false
            },
          },
        ]
      },
      {
        test: /\.css$/,
        exclude: /node_modules\/antd/,
        use: [
          require.resolve('style-loader'),
          {
            loader: require.resolve('css-loader'),
            options: {
              importLoaders: 1,
              modules:true,
              localIdentName:'[name]-[local]-[hash:base64:8]',
            },
          },
        ]
      },
忘了我 回答

MDN :

如果對象中不存在指定的屬性,Object.defineProperty()就創(chuàng)建這個屬性。當描述符中省略某些字段時,這些字段將使用它們的默認值。擁有布爾值的字段的默認值都是false。

意思是,如果你通過Object.defineProperty()創(chuàng)建新屬性,省略描述符的某些字段,如果值為布爾型,則為 false;

Reflect.getOwnPropertyDescriptor(Object.defineProperty({}, 'key', {value:1}),'key')//{value: 1, writable: false, enumerable: false, configurable: false}

如果你不通過 Object.defineProperty() 創(chuàng)建新的屬性,而是通過對象字面量創(chuàng)建屬性,默認值為 true ,高程說的沒問題;

Reflect.getOwnPropertyDescriptor({key:1},'key')//{value: 1, writable: true, enumerable: true, configurable: true}
let o={};
o.key=1;
Reflect.getOwnPropertyDescriptor(o,'key')//同上

另外,底層操作現(xiàn)在可以轉(zhuǎn)移到 Reflect 對象上來操作;

避風港 回答

我的做法是使用promise來處理多個上傳請求,然后每個上傳請求完成后返回地址。
全部上傳完成后在請求一次,保存這幾條地址到數(shù)據(jù)庫。

promisify.js:

module.exports = (api) => {
    return (options, ...params) => {
        return new Promise((resolve, reject) => {
            api(Object.assign({}, options, { success: resolve, fail: reject }), ...params);
        });
    }
}

我封裝的上傳函數(shù)upload,放在network.js中:

function upload(options) {
    var url = options.url,
        path = options.path,
        name = options.name,
        // data = options.data,
        extra = options.extra,
        success = options.success,
        progress = options.progress,
        fail = options.fail

    console.log("upload url:" + url)
    const uploadTask = wx.uploadFile({
        url: url,
        filePath: path,
        name: name,
        formData: extra,
        success: function (res) {
            console.log(res);

            var data = res.data
            try {
                data = JSON.parse(res.data)
                console.log(data)
            }
            catch (e) {
                console.log(data)
                throw(e)
            }

            if (res.statusCode == 200 && data.code == 1000) {
                if (success) {
                    success(data)
                }
            }
            else {
                if (fail) {
                    fail(data)
                }
            }

        },
        fail: function (res) {
            console.log(res)
            if (fail) {
                fail(res)
            }
        }
    })

    uploadTask.onProgressUpdate((res) => {
        console.log('上傳進度', res.progress)
        console.log('已經(jīng)上傳的數(shù)據(jù)長度', res.totalBytesSent)
        console.log('預期需要上傳的數(shù)據(jù)總長度', res.totalBytesExpectedToSend)
        if (progress) (
            progress(res)
        )
    })
}

module.exports = {
    upload: upload
}

上傳:

const network = require("../../utils/network.js")
const promisify = require("../../utils/promisify.js")

//轉(zhuǎn)為promise對象
const upload = promisify(network.upload)


//上傳函數(shù)
uploadMultiImage: function (paths) {
    let z = this
    
    let url = '...'

    const promises = paths.map(function (path) {
        return upload({
            url: url,
            path: path,
            name: 'file',
            extra: {},
        })
    })

    wx.showLoading({
        title: '正在上傳...',
    })
    
    Promise.all(promises).then(function (datas) {
        //所有上傳完成后
        
        wx.hideLoading()

        // 服務器返回的路徑
        let paths = datas.map(data => {
            return data.data
        })

        // 保存,這里可以選擇發(fā)送一個請求,保存這幾條路徑
        images = images.concat(paths)
        z.setData({
            images: images
        })
    }).catch(function (res) {
        wx.hideLoading()
        util.handleFail(res)
    })
}
撿肥皂 回答

ie控制臺會有報錯提示的你不妨看下,我建議把import 'babel-polyfill' 這一行移到最上面

掛念你 回答

沒用過iview

可以嘗試使用 jsx,然后在 render哪里寫jsx

怎么配置 vue 的jsx 相關插件,出門右轉(zhuǎn)vue官網(wǎng),很詳細。