Try our conversational search powered by Generative AI!

Is it important how you name ClientResources in module.config file?


This is my module.config:

<?xml version="1.0" encoding="utf-8"?>
        <add assembly="PROJECT.Web" />
        <add name="epi-cms.widgets.base" path="Styles/Styles.css" resourceType="Style"/>
        <add name="tinymce.plugins.extendedepilink" path="Styles/TinyMce.css" resourceType="Style"/>
            <add name="PROJECT" path="Scripts" />


Still, ClientResources/Styles/TinyMce.css is not loaded, although Styles.css has. I could import TinyMce.css to Styles.css, but since I want to make an Add-on out of this functionality, this is not an option.

I have tried clearing cache/temporary files/app restart... Could it be that the name should match something?

Apr 07, 2014 12:51

The name attribute is used for resource grouping, and resources which aren't "required" by anything won't be loaded.

When you use epi-cms.widgets.base as name for your style it will become a part of the resource group loaded when the cms ui is loaded. Your tinymce group is however not referenced, and will not be loaded. You can add references to script groups by adding a clientModule section in your config.

    <add dependency="CMS" type="runAfter" />
    <add name="tinymce.plugins.extendedepilink" />

This will load your resources when the CMS module has been loaded.

You can also add a client side initializer function to the clientModule element.


Apr 10, 2014 13:22

Thx so much, works like charm.

Just one minor issue, type should be RunAfter instead of runAfter (in this version at least - it's 7.5.1003.0)

Apr 11, 2014 16:24
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.