鍍金池/ 問答/ HTML問答
returns a value, the promise returned by then gets resolved with the returned value as its value;
throws an error, the promise returned by then gets rejected with the thrown error as its value;
returns an already resolved promise, the promise returned by then gets resolved with that promise's value as its value;
returns an already rejected promise, the promise returned by then gets rejected with that promise's value as its value.
returns another pending promise object, the resolution/rejection of the promise returned by then will be subsequent to the resolution/rejection of the promise returned by the handler. Also, the value of the promise returned by then will be the same as the value of the promise returned by the handler.
from here: https://developer.mozilla.org...
局外人 回答

opacity是改變元素的透明度,并不能改顏色。

命于你 回答

markPoint 這個(gè)是設(shè)置你框住的那個(gè)東西的,可以試一下;
series下的markPoint,也可以全局配置markPoint

大濕胸 回答

就是一個(gè)選項(xiàng)卡功能
wxml

 <view wx:for="{{banners}}"  wx:for-item="banner" wx:for-index="idx" >
 <image src="{{banner.img}}" />
 <view>
  <image wx:for="{{banner.imgs}}" data-idx="{{idx}}"  data-index="{{index}}"class="thumbnail {{banner.index==index?'cur':''}}" src="{{item}}"  catchtap="showBanner" />
 <text> {{banner.index}}</text>
 </view>
</view> 

wxss

.thumbnail{
  width: 100rpx;
  height: 100rpx;
  margin-right: 10rpx;
   border: 2px solid transparent;
}
.cur{
  border: 2px solid red;
}

js

Page({
    data: {
         banners: [
          {
            index: 0,
            img: 'https://gss1.bdstatic.com/9vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=a80e4a17ae014c080d3620f76b12696d/42166d224f4a20a40709fb7997529822720ed07d.jpg',
            imgs: ['https://gss1.bdstatic.com/9vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=a80e4a17ae014c080d3620f76b12696d/42166d224f4a20a40709fb7997529822720ed07d.jpg', 'https://gss1.bdstatic.com/9vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=00c4cfe352fbb2fb202650402e234bc1/d62a6059252dd42a711ec615043b5bb5c9eab87d.jpg', 'https://gss0.bdstatic.com/-4o3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike150%2C5%2C5%2C150%2C50/sign=66342e1187d4b31ce4319ce9e6bf4c1a/54fbb2fb43166d22639320c64a2309f79152d2ff.jpg', 'https://gss2.bdstatic.com/9fo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike180%2C5%2C5%2C180%2C60/sign=9e8ac1c952df8db1a8237436684ab631/3ac79f3df8dcd100784b38707e8b4710b8122f88.jpg'],

          },
          {
            index: 0,
            img: 'https://gss1.bdstatic.com/-vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=005e5fcd9aef76c6c4dff379fc7f969f/9358d109b3de9c8234db74636681800a18d843a4.jpg',
            imgs: ['https://gss1.bdstatic.com/-vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=005e5fcd9aef76c6c4dff379fc7f969f/9358d109b3de9c8234db74636681800a18d843a4.jpg', 'https://gss2.bdstatic.com/9fo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike180%2C5%2C5%2C180%2C60/sign=53d730f8daa20cf4529df68d17602053/8d5494eef01f3a2927a062b19325bc315c607c60.jpg', 'https://gss0.bdstatic.com/-4o3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=d45d73693f7adab429dd1311eabdd879/562c11dfa9ec8a134f6397a1fe03918fa0ecc072.jpg', 'https://gss2.bdstatic.com/-fo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike180%2C5%2C5%2C180%2C60/sign=5354a1279925bc313f5009ca3fb6e6d4/7e3e6709c93d70cf4566dee4f8dcd100bba12bbe.jpg'],

          },
          {
            index: 0,
            img: 'https://gss1.bdstatic.com/9vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=47772d4895510fb36c147fc5b85aa3f0/8326cffc1e178a8218bb1c51fd03738da877e8b8.jpg',
            imgs: ['https://gss1.bdstatic.com/9vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=47772d4895510fb36c147fc5b85aa3f0/8326cffc1e178a8218bb1c51fd03738da877e8b8.jpg', 'https://gss1.bdstatic.com/9vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike116%2C5%2C5%2C116%2C38/sign=4ab22f86f91fbe090853cb460a096756/e850352ac65c1038623ade32b9119313b17e89fd.jpg', 'https://gss2.bdstatic.com/-fo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike180%2C5%2C5%2C180%2C60/sign=82905fe6e0f81a4c323fe49bb6430b3c/5882b2b7d0a20cf4bf0e134d7d094b36adaf9982.jpg', 'https://gss0.bdstatic.com/94o3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike180%2C5%2C5%2C180%2C60/sign=83659ab63212b31bd361c57be7715d1f/622762d0f703918f50043b3b5a3d269758eec46e.jpg', 'https://gss2.bdstatic.com/-fo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike92%2C5%2C5%2C92%2C30/sign=c2765b7686b1cb132a643441bc3d3d2b/b8014a90f603738d5fa93cbbb81bb051f919ec4c.jpg'],

          },
        ],
    },
    showBanner:function(e){
      let i = e.target.dataset.idx,
          j = e.target.dataset.index,
          banners = this.data.banners;
      banners[i].index=j;
      banners[i].img = banners[i].imgs[j]
      this.setData({ 
        banners: banners
      })
    }
})

完整案例

情皺 回答

沒圖,看不懂你說什么。貼出的代碼耦合太高無法重現(xiàn)
我猜想你是要這個(gè)效果

<template>
  <ul>
    <li class="tree-menu-list">
      <a @click="toggle()">
        <i v-if="isFolder" class="iconfont" :class="[open ? 'icon-jiantouarrow487': 'icon-iconfontjiantou']"></i>
        <i v-if="!isFolder" class="iconfont"></i>
        {{ model.menuName }}
      </a>
      <ul v-show="open"  >
        <li v-for="(item, index) in model.children" :model="item" :key="index" v-text="item"  @click="sendParams(index)"></li>
        <!--<tree-menu v-for="(item, index) in model.children" :model="item" :key="index"></tree-menu>-->
      </ul>
    </li>
  </ul>
</template>
export default {
  name: 'HelloWorld',
//  props: ['model'],
  data () {
    return {
      model:{
        id:1314,
        menuName:'一級菜單',
        children:[
          '二級菜單1',
          '二級菜單2',
          '二級菜單3',
          '二級菜單4',
        ],
      },
      open: false,
      currentTab: false,
      isFolder: false,
//      isFolder: this.model.children && this.model.children.length ? true : false

    }
  },
  created(){
    this.isFolder=this.model.children && this.model.children.length
  },
  methods: {
    toggle: function () {
      console.log(this.isFolder);
      if (this.isFolder) {
        this.open = !this.open
      }
    },
    sendParams: function (i) {
      console.log(this.model.children[i]);
//      this.$router.push({
//        path: '/info',
//        name: 'info',
//        query: {
//          id: this.model.id,
//          name: this.model.menuName
//        }
//      })
    }
  }
}
</script>
久舊酒 回答

看看是不是重定向的問題,404頁面放在異步路由里面的最后面!

舊言 回答

node的環(huán)境變量配一下

喜歡你 回答

首先這個(gè)列表線路這個(gè)數(shù)組里面每個(gè)選項(xiàng)增加一個(gè)屬性disabled,默認(rèn)都是true,然后循環(huán)的時(shí)候,線路名稱用input,disabled屬性為當(dāng)前選項(xiàng)的disabled,然后點(diǎn)擊對號的時(shí)候,把index傳入,把數(shù)組的這個(gè)index的disabled屬性修改為false,即可編輯,
-------希望能幫助你

淡墨 回答

23是最低要求,可能文檔沒有描述清楚,高于就行。

北城荒 回答

在webpack配置文件的rules數(shù)組中添加打包字體文件的loader,記得npm install --save -D url-loader,如下:

{

    test: /\.(woff2?|eot|ttf|otf)(\?.*)?$/,
    loader: 'url-loader',
    options: {
      limit: 10000,
      name: utils.assetsPath('fonts/[name].[hash:7].[ext]')
    }
  }
魚梓 回答

的確ES6的importexport一定是要在最外層,不能被包含在函數(shù)或是代碼塊中。
但是這里實(shí)際上并沒有使用imports-loader吧,雖然在webpack中有配置,但是在js中并不是通過require+參數(shù)方式使用。

可以多研究下imports-loader的文檔。
https://www.npmjs.com/package...

撥弦 回答

使用connect吧,如果對react redux不熟悉,可能會引起未知的異常。

短嘆 回答

以前學(xué)java的時(shí)候,碰到過很多類似這種后臺管理系統(tǒng)在開源中國上。
https://gitee.com/explore/sta...

純妹 回答

盡量把代碼貼完整,沒有看到export 也沒有看到import .

赱丅呿 回答

$vux.bus && $vux.bus.$emit('vux:after-view-enter')

我也是找了半天沒找到 他在哪里注冊的$vux 郁悶了

心上人 回答

1.建議封裝下
2.建議在api配置的時(shí)候加上參數(shù)用來決定是否在header中帶token

export const API = {
    login:{
        url: '////',
        method: 'post',
        token: true
    },
    ...
}
我們對請求做了封裝,可以傳一個(gè)api接口對象,在攔截器里在對最終對傳參序列化

3.可以把token存在緩存,判斷沒有時(shí)再去storage中取

故人嘆 回答

var operators = ['未登錄1','未登錄2','未登錄3','未登錄4','未登錄5'];

operators.map(function(value){

return { 'name': value }

})