public static IServiceCollection AddModuleFolder(
            [NotNull] this IServiceCollection services,
            [NotNull] string virtualPath)
        {
            return(services.Configure <ExtensionHarvestingOptions>(options => {
                var expander = new ModuleLocationExpander(
                    DefaultExtensionTypes.Module,
                    new[] { virtualPath },
                    "Module.txt"
                    );

                options.ModuleLocationExpanders.Add(expander);
            }));
        }
        public static IServiceCollection AddModuleFolder(
            [NotNull] this IServiceCollection services,
            [NotNull] string virtualPath)
        {
            return services.Configure<ExtensionHarvestingOptions>(options => {
                var expander = new ModuleLocationExpander(
                    DefaultExtensionTypes.Module,
                    new[] { virtualPath },
                    "Module.txt"
                    );

                options.ModuleLocationExpanders.Add(expander);
            });
        }
예제 #3
0
        public static IServiceCollection AddThemeFolder(
            this IServiceCollection services,
            string virtualPath)
        {
            return(services.Configure <ExtensionHarvestingOptions>(configureOptions: options =>
            {
                var expander = new ModuleLocationExpander(
                    DefaultExtensionTypes.Theme,
                    new[] { virtualPath },
                    "Theme.txt"
                    );

                options.ModuleLocationExpanders.Add(expander);
            }));
        }
        public static IServiceCollection AddThemeFolder(
            this IServiceCollection services,
            string virtualPath)
        {
            return services.Configure<ExtensionHarvestingOptions>(configureOptions: options =>
             {
                 var expander = new ModuleLocationExpander(
                     DefaultExtensionTypes.Theme,
                     new[] { virtualPath },
                     "Theme.txt"
                     );

                 options.ModuleLocationExpanders.Add(expander);
             });
        }