AnsweredAssumed Answered

css loaded as javascript with 4.0.1EE

Question asked by lotharmärkle on Jun 14, 2012
Latest reply on Jun 16, 2012 by afaust
Hi,

I have the following extension module defined which loads a dependent css and javascript files. But the css is rendered into a <script> tag instead of a css @import with 4.0.1EE. Chrome complains about invalid javascript while interpreting the css… As it works with 4.0dCE is there something wrong with the xml here or should this be raised in JIRA (could not find any related issue)?


<extension>
   <modules>
      <module>
         <id>test-module</id>
         <auto-deploy>true</auto-deploy>
         <customizations>
            <customization>
               <dependencies>
                  <css>/res/components/test.css</css>
                  <js>/res/components/test1.js</js>
                  <js>/res/component/test2.js</js>
               </dependencies>
            </customization>
         </customizations>
      </module>
   </modules>
</extension>

This is the result in HTML, see the css is referenced by a <script> tag:


   <!– Extension Module Dependencies –>

   <script type="text/javascript" src="/share/res/components/test1.js"></script>
   <script type="text/javascript" src="/share/res/components/test2.js"></script>
   <script type="text/javascript" src="/share/res/components/test.css"></script>


Thanks

Outcomes