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

鍍金池/ 問答/ HTML問答
不歸路 回答

1.express 不需要打包
2.把前端代碼打包到express的靜態(tài)目錄下
3.express路由寫好,在模版html里(一般是jade或者ejs)引用靜態(tài)目錄下的打包后的js和css
4.開啟express的端口監(jiān)聽

注意:
1.模板html的飲用路徑是服務(wù)器的訪問路徑,不是項目內(nèi)的文件和文件的路徑
2.前端打包每個人都會可能會碰到問題,要嘗試解決一下

離夢 回答

實際上你的方法是很好的了

如果覺著比較麻煩,可以用nodejs批量處理一下,會很快。

issue1: css權(quán)重問題;id選擇器優(yōu)先于class選擇器;
issue2: toggleClass已經(jīng)執(zhí)行,只是alert中斷了樣式的重繪;
你可以在toggleClass中使用function,在function中打印日志,然后會發(fā)現(xiàn)日志打印成功,然后alert,然后alert關(guān)閉后,樣式變更才生效

淡墨 回答
@connect(
    state => state.auth
)

@connect接受一個函數(shù)作為參數(shù),將這個函數(shù)的返回值對象展開傳給組件,即作為組件的props

陌南塵 回答

withCredentials的情況下,后端要設(shè)置Access-Control-Allow-Origin為你的源地址,例如http://localhost:8080,不能是*,而且還要設(shè)置header('Access-Control-Allow-Credentials: true');

旖襯 回答

不難理解,父組件把自身的函數(shù)func_click通過props->funClick傳給子組件,子組件調(diào)用funClick就等于調(diào)用了父組件的func_click實現(xiàn)了數(shù)據(jù)交互
但官方是推薦按你的思路 即通過$emit進行數(shù)據(jù)交互的

維她命 回答

自己沒加分號,難怪一直不行

瞄小懶 回答

$('#active').attr('transform-origin',screenHeightNew +" "+screenWidthNew )

胭脂淚 回答

我只能簡單說一下,iconfont的圖標(biāo)實際上是“字”,你看他們的介紹叫字體圖標(biāo),而“字”是有font-size color這些屬性的,至于說運用了什么技巧,可能就是把圖標(biāo)轉(zhuǎn)換為了"字"吧。說的不對還請見諒

枕頭人 回答

有個折中的辦法,你打開F12 network面板測試下加載然后點停止加載看看請求就知道了
clipboard.png

只要你能夠監(jiān)聽到當(dāng)前頁面資源加載的情況就知道有沒有點擊了

怣人 回答

給你一個思路,不知道get沒get你的意思

首先用js對圖片寬高進行縮放,這個比較容易。

然后用很多種方式可以水平垂直居中;

margin-left: 50%;
margin-top: 50%;
transform: translate(-50%, -50%)

或者在 flex 內(nèi)部

margin:auto

葬憶 回答

給 this.props.children 處理下呢const children = arrayify(this.props.children)

心沉 回答

你的elementUI是哪個版本看了下:2.1才有這個屬性

尐飯團 回答

邏輯改善:
1.在文本框blur時觸發(fā)校驗重復(fù)的API。如果重復(fù)直接提醒用戶重復(fù),重新填寫;
2.不要循環(huán)調(diào)用接口傳遞單個name,而是寫成對象/數(shù)組等一次性提交所有的數(shù)據(jù)

你的瞳 回答

路徑不對吧 public/dist/bundle.js

夢一場 回答

在行中的每個check都要記錄在dataSource中。

  • columus
const columnsMenu = [
      {
        title: '菜單',
        key: 'NAME',
        dataIndex: 'NAME',
      },
      {
        title: '全部',
        key: 'AUTHORITY_ALL',
        dataIndex: 'AUTHORITY_ALL',
        render: (text, record) => (<Checkbox onChange={(e) => this.handleCheckbox(e.target.checked, 'AUTHORITY_ALL', record.ID)} checked={record.AUTHORITY_ALL} value={record.ID} />),
      },
      {
        title: '查看權(quán)限',
        key: 'AUTHORITY_CHECK',
        dataIndex: 'AUTHORITY_CHECK',
        render: (text, record) => (<Checkbox onChange={(e) => this.handleCheckbox(e.target.checked, 'AUTHORITY_CHECK', record.ID)} checked={record.AUTHORITY_CHECK} value={record.ID} />),
      },
      {
        title: '編輯權(quán)限',
        key: 'AUTHORITY_EDIT',
        dataIndex: 'AUTHORITY_EDIT',
        render: (text, record) => (<Checkbox onChange={(e) => this.handleCheckbox(e.target.checked, 'AUTHORITY_EDIT', record.ID)} checked={record.AUTHORITY_EDIT} value={record.ID} />),
      },
    ];
  • handleCheckbox
handleCheckbox(checked, type, id) {
    let {dataSource} = this.props;
    dataSource = dataSource.map(data => {
        if(data.ID === id) {
            data[type] = checked;
            if(type === 'AUTHORITY_ALL') {
                data['AUTHORITY_EDIT'] = checked;
                data['AUTHORITY_CHECK'] = checked;
            } else {
                data['AUTHORITY_ALL'] = data['AUTHORITY_EDIT'] && data['AUTHORITY_CHECK'];
            }
        }
        return data;
    });
    
    dispatch({type: 'xxxx', dataSource});
}