Created
January 3, 2022 12:46
-
-
Save tslazarov/038a859a7f9e5af1b86e39ec1f60fbfb to your computer and use it in GitHub Desktop.
Sitefinity Image Optimization
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.ComponentModel; | |
using System.Diagnostics.CodeAnalysis; | |
using Progress.Sitefinity.ImageOptimization.Configuration; | |
using Telerik.Sitefinity.Abstractions; | |
using Telerik.Sitefinity.Configuration; | |
using Telerik.Sitefinity.Localization; | |
namespace Progress.Sitefinity.ImageOptimization | |
{ | |
/// <summary> | |
/// Contains the application startup event handlers registering the required components for the packaging module of Sitefinity. | |
/// </summary> | |
[ExcludeFromCodeCoverage] | |
public static class Startup | |
{ | |
/// <summary> | |
/// Called before the Asp.Net application is started. Subscribes for the logging and exception handling configuration related events. | |
/// </summary> | |
[EditorBrowsable(EditorBrowsableState.Never)] | |
public static void OnPreApplicationStart() | |
{ | |
Bootstrapper.Bootstrapped -= Bootstrapper_Bootstrapped; | |
Bootstrapper.Bootstrapped += Bootstrapper_Bootstrapped; | |
} | |
private static void Bootstrapper_Bootstrapped(object sender, EventArgs e) | |
{ | |
// ... | |
Res.RegisterResource<ImageOptimizationResources>(); | |
Config.RegisterSection<ImageOptimizationConfig>(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment