Try our conversational search powered by Generative AI!

Loading...
Area: Optimizely CMS
Applies to versions: 12 and higher
Other versions:
ARCHIVED This content is retired and no longer maintained. See the version selector for other versions of this topic.

Debugging CMS UI

Recommended reading 
Note: This documentation is for the preview version of the upcoming release of CMS 12/Commerce 14/Search & Navigation 14. Features included here might not be complete, and might be changed before becoming available in the public release. This documentation is provided for evaluation purposes only.

To debug the Optimizely CMS user interface, you can run your site with uncompressed JavaScript in edit view. To do this, you need to enable debug mode for client resources by using EPiServer.Framework.Web.Resources.ClientResourceOptions class add setting the Debug property to true.

Example configuration:

if (_webHostingEnvironment.IsDevelopment())
{    
    services.Configure<ClientResourceOptions>(uiOptions =>
    {
        uiOptions.Debug = true;
    });
}

How it works

The Optimizely CMS UI NuGet packages contain all the JavaScript files required to run the user interface compressed into a zip file. The system then reads the contents of the zip file at run time. At initialization, if the client resources debug flag is set to true, the system first looks for a debug version of the JavaScript zip file and, if it exists, loads that instead.

EPiServer.CMS.UI.Sources

The EPiServer.CMS.UI.Sources NuGet package contains all original user interface source files together with uncompressed Dojo and Dijit.

The source package is built as part of every release so it ties quite simply into the continuous release cycle. You can install it the same way you would any other NuGet package from nuget.optimizely.com.

Install-Package EPiServer.CMS.UI.Sources

If you need to manipulate sources files and then create a customized Dojo build you can use this package. It comes together with all Dojo build tools.

Note: To debug the Optimizely edit view, you do not need this package. The change described above is sufficient.

Do you find this information helpful? Please log in to provide feedback.

Last updated: Jul 02, 2021

Recommended reading