Calling all developers! We invite you to provide your input on Feature Experimentation by completing this brief survey.
Calling all developers! We invite you to provide your input on Feature Experimentation by completing this brief survey.
Hello
In module.config there should be only one client module with one client initializer. A client modules should have initialize method like in the example here. The rest of modules client components can be initialized in the initialize method. You can also take a look on epi/shell/ShellModule as an example (you might need to install "EPiServer Edit UI – Client side debug support" add-on in order to see the source code)
Hi all,
I have a couple of dojo/dijit components that ive developed for V7. They are both within my main VS project and therefore the module.config file is in the root.
My module.config looks like so:
<?xml version="1.0" encoding="utf-8"?>
<module>
<assemblies loadLocalBin="true">
<add assembly="MyAssembly" />
</assemblies>
<dojoModules>
<add name="communityuser" path="CommunityUser/Scripts" />
<add name="user" path="User/Scripts" />
</dojoModules>
<clientResources>
<add name="user.requiremodule" path="user/Scripts/RequireModule.js" resourceType="Script" />
<add name="communityuser.requiremodule" path="communityuser/Scripts/RequireModule.js" resourceType="Script" />
</clientResources>
<clientModule initializer="user/Initialize">
<requiredResources>
<add name="user.requiremodule" />
</requiredResources>
</clientModule>
<clientModule initializer="communityuser/ModuleInitializer">
<requiredResources>
<add name="communityuser.requiremodule" />
</requiredResources>
</clientModule>
</module>
The problem im running into is that only one of the initializer methods are ever called, whichever one is in the module.config file first. In the example above the user/Initialize file will be called, if I swap the order of the clientModule's, the communityuser/ModuleInitializer file will be called.
Any pointers please? Do i perhaps need to have seperate files, one for each component?
Thanks in advance
Al