Webpack入門教程二十五

來源:互聯網
上載者:User

標籤:webpack入門教程二十五

119.輸出HtmlWebpackPlugin.options中的內容,修改模板檔案index.html,代碼如下
<!DOCTYPE html><html><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><title>webpack demo</title><link rel="stylesheet" href=""></head><body><% for (var key in htmlWebpackPlugin.options) {%><%= key %> : <%= JSON.stringify(htmlWebpackPlugin.options[key]) %><% } %></body></html>
120.使用cnpm run webpack命令重新打包

650) this.width=650;" src="https://s5.51cto.com/wyfs02/M00/8D/C7/wKioL1iqrrDDwjzYAABFVd-z-kU974.png-wh_500x0-wm_3-wmp_4-s_2074528850.png" title="120.png" alt="wKioL1iqrrDDwjzYAABFVd-z-kU974.png-wh_50" />

121.查看產生的index-d331f7ab6afb27b67263.html檔案輸出的內容

650) this.width=650;" src="https://s5.51cto.com/wyfs02/M02/8D/C9/wKiom1iqru2y4grdAAEQ0aoKJg8078.png-wh_500x0-wm_3-wmp_4-s_2776265693.png" title="121.png" alt="wKiom1iqru2y4grdAAEQ0aoKJg8078.png-wh_50" />

本文出自 “素顏” 部落格,請務必保留此出處http://suyanzhu.blog.51cto.com/8050189/1899531

Webpack入門教程二十五

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.