有了Browser Link 基本上就是把 vs2013 當 Dreamweaver 來用了
- 首先,需要 vs2013,
- 下載安裝後開啟。
- 選 檔案/新增/專案 (ctrl-shift-N)
4.確定後將網頁 copy 到 WebApplication1 專案底下
5.打開 web.config 加入以下程式碼在 <configuration> </configuration> 區段中間後存檔,再按上面 google chrome 除錯按鈕
<system.webServer>
<handlers>
<add name="Browser Link for HTML" path="*.html" verb="*"
type="System.Web.StaticFileHandler, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
resourceType="File" preCondition="integratedMode" />
</handlers>
</system.webServer>
6.在空白處按 ctrl + 滑鼠右鍵,即會出現 browser link 選單,點一下 Inspect,再將游標移到 " 關於我們",vs2013 也會將 程式碼的 " 關於我們" 反白
7.點 Design 則可以在 chrome 裏面直接修改網頁,改完後 按 "saveF12Changes", 則會將網頁存檔,就像在 vs2013裏面存檔一樣。
8.這個方法很適合不熟悉 html 碼的朋友,提高學習興趣。
參考網址:Using Browser Link in Visual Studio 2013
留言列表