public static IAppBuilder UseNEventStoreViewer(this IAppBuilder builder, NEventStoreViewerApiConfig config) { var configurator = new NEventStoreViewerApiConfigurator(config); configurator.RegisterApi(builder); return builder; }
public void Configuration(IAppBuilder app) { app.UseCors(CorsOptions.AllowAll); var config = new NEventStoreViewerApiConfig { EnableSwagger = true, ConnectionString = ConfigurationManager.AppSettings["ConnectionString"] }; app.Map("/viewer", map => map.UseNEventStoreViewer(config)); }