jenkinsjenkins-pluginsjelly

How add a CSS Jelly file to Jenkins Plugin?


I have made my own stylesheet that I require to include on the Jenkins plugin.

   <l:layout css="/plugin/myPlugin/css/jquery-ui.css">
        <link rel="stylesheet" href="${rootURL}/plugin/myPlugin/jquery-ui.css" type="text/css" media="screen" />

Please advice me..

Thanks..


Solution

  • To link CSS files in Jelly files is deprecated, see jelly tags documentation:

    This was originally added to allow plugins to load their stylesheets, but the use of thie 
    attribute is discouraged now. plugins should now do so by inserting <style> elements 
    and/or <script> elements in <l:header/> tag.
    

    Please use inline css tags instead (code example).