Skip to content

Instantly share code, notes, and snippets.

View LucGosso's full-sized avatar
😀

Luc Gosso LucGosso

😀
View GitHub Profile
using Azure.Storage.Blobs;
public string UploadJsonToAzureBlobStorage(string json)
{
// Name of the share, directory, and file
string shareName = ConfigurationManager.AppSettings.Get("inRiver.StorageAccountShareReference");
string storageAccountName = ConfigurationManager.AppSettings.Get("inRiver.StorageAccountName");
string storageAccountKey = ConfigurationManager.AppSettings.Get("inRiver.StorageAccountKey");
@LucGosso
LucGosso / counter.razor
Last active April 14, 2022 13:28
Different razor component approaches
<component type="typeof(Counter)" render-mode="ServerPrerendered"
param-Count="@Model.StartCount" />
___above in cshtml________below in razor____________
@using Microsoft.AspNetCore.Components
<p>Current count: @Count</p>
<button @onclick="IncrementCount" class="btn btn-primary">Click me</button>
using EPiServer;
using EPiServer.Cms.UI.AspNetIdentity;
using EPiServer.Core;
using EPiServer.Logging;
using EPiServer.Notification;
using EPiServer.ServiceLocation;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Identity;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json;