[WordPress] 外掛分享: LESS Compiler

首頁外掛目錄 › LESS Compiler
WordPress 外掛 LESS Compiler 的封面圖片
10+
安裝啟用
尚無評分
4205 天前
最後更新
問題解決
WordPress 3.9+ v1.6 上架:2014-05-10

內容簡介

透過 WordPress 外掛,從儀表板輕鬆編寫 LESS、編輯變量並編譯樣式表。

閱讀文檔

註冊和併入 LESS 樣式表的方式與 CSS 相同。

`

wp_enqueue_style( ‘my-less-handle’, ‘http://example.com/css/mystyle.less’, $deps, $ver, $media );
`

透過 less_configuration 過濾器來配置外掛程式。

即使您使用 CSS 框架,也可以不設置外掛程式的配置,但您至少應該註冊您的變量。

設置 LESS 變量值

`

less_set( $variable, $value );
`

取得 LESS 變量值

`

less_get( $variable );
`

您很可能會在您的佈景主題的 functions.php 裡使用這些函數。

此外掛使用 Less.php 編譯器。

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.6) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「LESS Compiler」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

Write LESS, edit your variables and compile your stylesheet from your dashboard.
Read the documentation

Register and enqueue your LESS sheets the same way you would do for your CSS.
`

wp_enqueue_style( ‘my-less-handle’, ‘http://example.com/css/mystyle.less’, $deps, $ver, $media );
`

Configure the plugin with the less_configuration filter.
Configuration of the plugin is optional, but you should at least register your variables if you are using a CSS framework.

Set a LESS variable value
`

less_set( $variable, $value );
`

Get a LESS variable value
`

less_get( $variable );
`

You will most likely use these functions in your theme’s functions.php.
The plugin uses the Less.php Compiler.

延伸相關外掛

文章
Filter
Mastodon