99re热这里只有精品视频,7777色鬼xxxx欧美色妇,国产成人精品一区二三区在线观看,内射爽无广熟女亚洲,精品人妻av一区二区三区

標示注釋

2018-02-24 15:11 更新

理想上,任何?CSS 規(guī)則集之前都應該使用 C 風格注釋來解釋 CSS 塊的核心。這個注釋也要記錄對規(guī)則集特定部分編號的解釋。比如:

/**
 * Helper class to truncate and add ellipsis to a string too long for it to fit
 * on a single line.
 * 1\. Prevent content from wrapping, forcing it on a single line.
 * 2\. Add ellipsis at the end of the line.
 */
.ellipsis {
  white-space: nowrap; /* 1 */
  text-overflow: ellipsis; /* 2 */
  overflow: hidden;
}

基本上,任何不能明顯看出意義的地方都應該注釋,但不要隨處注釋。記住不要注釋太多,掌握尺度讓每一處注釋都有意義。

當注釋 Sass 的一個特定部分時,應該使用 Sass 單行注釋而不是 C 風格的注釋塊。這么做將不會輸出注釋,即使是在開發(fā)時的擴展模式。

// Add current module to the list of imported modules.
// `!global` flag is required so it actually updates the global variable.
$imported-modules: append($imported-modules, $module) !global;

擴展閱讀

以上內容是否對您有幫助:
在線筆記
App下載
App下載

掃描二維碼

下載編程獅App

公眾號
微信公眾號

編程獅公眾號