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

鍍金池/ 問答/ HTML問答
話寡 回答

可以看看一些開源的組件庫的設(shè)計,比如:

https://www.iviewui.com/compo...

它設(shè)計了 2 個組件:

  • Breadcrumb
  • BreadcrumbItem 這個里面是真正跳轉(zhuǎn)用的 a 標(biāo)簽
吢涼 回答

解決

      const test = [1, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3]
      const func = function (arry, length) {
        let result = []
        arry.forEach((ele, index) => {
          const i = Math.floor(index / length)
          console.log(i)
          if (!result[i]) {
            result[i] = []
          }
        })
        return result
      }
      console.log(func(test, 5))

原理

就是除法運算,根據(jù)需要的長度來組合二維數(shù)組
有點類似于九九乘法表

枕邊人 回答

多了個<導(dǎo)致語法錯誤。。

陪妳哭 回答
function complete(req, callback) {
  req.then(callback, callback);
}

var req = axios(...)

complete(req, () => ...);
瘋浪 回答

不一定全都要使用它的,可以自己編寫樣式替換掉不合適掉

放開她 回答

代碼/效果截圖如下,兼容性未做。建議直接圖片代替這種按鈕。

<div class="button">確認(rèn)</div>

.button {
  position: relative;
  width: 120px;
  height: 30px;
  color: #1e9cd8;
  border-radius: 16px;
  font-size: 18px;
  text-align: center;
  border: 4px solid transparent;
  background: #ffff;
  background-clip: padding-box;
}

.button::after {
  position: absolute;
  top: -4px;
  bottom: -4px;
  left: -4px;
  right: -4px;
  content: '';
  background: linear-gradient(90deg, #0379c2, #22dff3);
  z-index: -1;
  border-radius: 16px;
}

圖片描述

小曖昧 回答

加載到數(shù)據(jù)后,先獲取當(dāng)前滾動體的內(nèi)容長度,然后將數(shù)據(jù)裝載進(jìn)入,同時將滾動條重新定位到之前的位置即可。

有點壞 回答

||表示邏輯或,會嘗試將符號左側(cè)轉(zhuǎn)換為Boolean對象,如果左側(cè)為true則表達(dá)式結(jié)果為左側(cè)值,如果為false,則表達(dá)式結(jié)果為右側(cè)值。

在ES5的年代,這種寫法多用于處理默認(rèn)值。

結(jié)合截圖來說:如果nodes[link.source]false,則給nodes[link.source]賦值為一個Object,并將其返回。
如果nodes[link.source]不為false,則直接返回nodes[link.source]

P.S. 上邊所說的false不是真正意義上的Boolean false,而是所有可以轉(zhuǎn)換為false的值,包含null、undefined0之類的

六扇門 回答

你有沒有調(diào)用表單驗證:

this.$refs['form'].validate(valid => {
    if (valid) {
        // 驗證通過
    } else {
        // 任一項驗證失敗
    }
})
小曖昧 回答

1.首先 小程序 生成 date 對象需要使用 getDate函數(shù), 返回一個當(dāng)前時間的對象。
2.小程序let會報錯

module.exports = function (value) {
  if (!value) {
    return ''
  }
  var date = getDate(value)
  var time = getDate().getTime() - date.getTime() // 現(xiàn)在的時間-傳入的時間 = 相差的時間(單位 = 毫秒)
  if (time < 0) {
    return ''
  } else if ((time / 1000 < 30)) {
    return '剛剛'
  } else if (time / 1000 < 60) {
    return parseInt((time / 1000)) + '秒前'
  } else if ((time / 60000) < 60) {
    return parseInt((time / 60000)) + '分鐘前'
  } else if ((time / 3600000) < 24) {
    return parseInt(time / 3600000) + '小時前'
  } else if ((time / 86400000) < 31) {
    return parseInt(time / 86400000) + '天前'
  } else if ((time / 2592000000) < 12) {
    return parseInt(time / 2592000000) + '月前'
  } else {
    return parseInt(time / 31536000000) + '年前'
  }
}
 <wxs src="./ccc.wxs" module="time" /> 
 <view>{{time('2018-04-26T09:51:19.808Z')}}</view>

測試 這樣是可以實現(xiàn)的

真難過 回答

可以的,修改webpack的publicPath為dev.baidu.com就可以了,不過得確保你的app.js可以訪問,試試

http://dev.baidu.com/app.js

小眼睛 回答

IE8 has virtually no ES5 support, but does support Object.defineProperty, Object.getOwnPropertyDescriptor, JSON parsing & Property access on strings.

來源: Can I use

IE8 實現(xiàn)了 Object.defineProperty() 方法,但 只能在 DOM 對象上使用

來源: MDN

淚染裳 回答

comment組件未渲染完成。
你可以把

QC.Login({
   btnId:"qqLoginBtn"    //插入按鈕的節(jié)點id
});

放到comment組件里去用

骨殘心 回答
// /[0-9]/.test(str) str中有一個數(shù)字都返回 true
// !/[0-9]/.test(str) str中沒有一個數(shù)字才返回 true
if($("#code").val().length!=3 && !/[0-9]/.test($("#code").val())){

}
好難瘦 回答

為什么要寫那么復(fù)雜?

import React, { Component } from 'react'
import './styles.css'

class App extends Component {
  constructor() {
    super()
    this.state = {
      list: ['A', 'B', 'C', 'D'],
      current: 0,

      content: [
        ['img a-1', 'img a-2', 'img a-3'],
        ['img b-1', 'img b-2', 'img b-3'],
        ['img c-1', 'img c-2', 'img c-3'],
        ['img d-1', 'img d-2', 'img d-3']
      ]
    }
  }

  handleClick = index => this.setState({ current: index })

  render() {
    return (
      <div className="tab-panel">
        <ul className="tabs">
          {this.state.list.map((v, i) => (
            <li
              key={v}
              className={i === this.state.current ? 'active' : ''}
              onClick={() => this.handleClick(i)}
            >
              {v}
            </li>
          ))}
        </ul>

        <ul className="content-container">
          {this.state.content.map(
            (v, i) =>
              v.length && (
                <li key={i} className={i === this.state.current ? 'show' : 'hidden'}>
                  {v.map((img, index) => <img key={index} src={img} alt={img} />)}
                </li>
              )
          )}
        </ul>
      </div>
    )
  }
}

export default App