Ben  McKernan
Apr 18, 2013
  9645
(2 votes)

Changes to the module.config for EPiServer 7.1

I’ve seen on the forum that there have been several people having issues running their custom dojo code after the EPiServer 7.1 update. So I thought I’d mention these issues, their cause and the solution.

Required Resources Key Changed for CMS

So I’ve demonstrated in previous blog posts that it’s possible to initialize a module without having a component. This was done by using a little trick to add an initializer script to the required resources for CMS by adding the following to your module.config file.

<clientResources>
  <add name="epi.cms.widgets.base" path="initialize.js" resourceType="Script" />
</clientResources>

With the upgrade to dojo 1.8.3 we changed the dojo package name for CMS to be epi-cms. This is due to the fact that dojo has made changes in their loader which means that dot or slash separated package names are no longer supported. To be consistent with our naming we also changed the key for required resources. So the following are now the required resource keys:

EPiServer 7: epi.cms.widgets.base

EPiServer 7.1: epi-cms.widgets.base

JavaScript Package Naming

As mentioned previously dojo have changed their loader to be fully AMD compliant and as such dot or slash separated names are no longer supported. For example the following is no longer supported:

<dojoModules>
  <add name="my.addon" path="scripts/addon" />
</dojoModules>

My suggestion if you are in this situation is to change the delimiter from dot or slash to be a dash instead. Meaning that in the above example the package name would instead be my-addon.

Hopefully this helps anybody who runs into similar issues!

Apr 18, 2013

Comments

Mike Cockrell
Mike Cockrell Apr 18, 2013 03:41 PM

Great post Ben, hopefully this will solve other UI modder's problems!

Please login to comment.
Latest blogs
Opti ID overview

Opti ID allows you to log in once and switch between Optimizely products using Okta, Entra ID, or a local account. You can also manage all your use...

K Khan | Jul 26, 2024

Getting Started with Optimizely SaaS using Next.js Starter App - Extend a component - Part 3

This is the final part of our Optimizely SaaS CMS proof-of-concept (POC) blog series. In this post, we'll dive into extending a component within th...

Raghavendra Murthy | Jul 23, 2024 | Syndicated blog

Optimizely Graph – Faceting with Geta Categories

Overview As Optimizely Graph (and Content Cloud SaaS) makes its global debut, it is known that there are going to be some bugs and quirks. One of t...

Eric Markson | Jul 22, 2024 | Syndicated blog

Integration Bynder (DAM) with Optimizely

Bynder is a comprehensive digital asset management (DAM) platform that enables businesses to efficiently manage, store, organize, and share their...

Sanjay Kumar | Jul 22, 2024

Frontend Hosting for SaaS CMS Solutions

Introduction Now that CMS SaaS Core has gone into general availability, it is a good time to start discussing where to host the head. SaaS Core is...

Minesh Shah (Netcel) | Jul 20, 2024

Optimizely London Dev Meetup 11th July 2024

On 11th July 2024 in London Niteco and Netcel along with Optimizely ran the London Developer meetup. There was an great agenda of talks that we put...

Scott Reed | Jul 19, 2024