Sample with boilerplate code for an Optimizely add-on.
Solution consists of one project for the add-on (Addon folder), and a second project for the website (Website folder).
The website project was set up using the Optimizely CMS empty Visual Studio template.
- Clone project
- Create empty database and update
appsettings.json(or runcreate-db.batin the solution folder if you're using LocalDB) - Start Website project and browse to https://localhost:44300/ which will prompt you to create an admin user
- Access the Optimizely UI through: https://localhost:44300/episerver/cms using the credentials of the admin user
- Create a new page of type
SamplePageType - Notice how the
SomeStringproperty has a wider textbox for editing
- Load client resources from add-on project to make refreshing client resources easier (see
ServiceCollectionExtensions.csin Addon project). - Enable UI debugging (see
ServiceCollectionExtensions.csin Addon project). - Add the
EPiServer.UI.SourcesNuGet package to get uncompressed source code of the Optimizely UI including Dojo.