Skip to content

Instantly share code, notes, and snippets.

Sipke Schoorstra sfmskywalker

Block or report user

Report or block sfmskywalker

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View AuthenticatingHandler.cs
public class AuthenticatingHandler<T> : DelegatingHandler where T : ISecurityTokenAccessor
{
private readonly Policy<HttpResponseMessage> _policy;
private readonly T _securityTokenAccessor;
private IAccessToken _accessToken;
private AuthenticationHeaderValue _authenticationHeader;
public AuthenticatingHandler(T securityTokenAccessor)
{
_securityTokenAccessor = securityTokenAccessor;
View generate-theme.cmd
dotnet new octheme -n "MadeWithLoveTheme"
@sfmskywalker
sfmskywalker / InstallCodeGenerationTemplates.cmd
Created Jul 29, 2018
Installs the Orchard Core Code Generation Templates
View InstallCodeGenerationTemplates.cmd
dotnet new -i OrchardCore.Cms.Templates::1.0.0-beta2-*
@sfmskywalker
sfmskywalker / NewProject.cmd
Last active Jul 29, 2018
Create new ASP.NET Core Orchard Core Project
View NewProject.cmd
dotnet new web --name "AngularWidgetsDemo"
cd "AngularWidgetsDemo"
dotnet add package "OrchardCore.Application.Cms.Targets" --version 1.0.0-beta2-*
@sfmskywalker
sfmskywalker / DownloadAngularElementSample.ps1
Last active Jul 29, 2018
Downloads and extracts a sample Angular Custom Element from GitHub
View DownloadAngularElementSample.ps1
Add-Type -AssemblyName System.IO.Compression.FileSystem
Invoke-WebRequest -Uri https://github.com/nitayneeman/made-with-love/archive/release/v1.1.0.zip -OutFile ./ClientApp.zip
[System.IO.Compression.ZipFile]::ExtractToDirectory("c:\Code\Orchard Core and Angular\AngularWidgetsDemo\ClientApp.zip", "c:\Code\Orchard Core and Angular\AngularWidgetsDemo")
Rename-Item made-with-love-master ClientApp
@sfmskywalker
sfmskywalker / npm-install.cmd
Last active Jul 29, 2018
Executes the NPM Install command
View npm-install.cmd
cd ClientApp
npm install
ng build
@sfmskywalker
sfmskywalker / IncludeElements.cmd
Last active Jul 29, 2018
Add Angular Elements & Polyfill
View IncludeElements.cmd
cd ClientApp
ng add @angular/elements
View Startup.cs
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.DependencyInjection;
namespace AngularWidgetsDemo
{
public class Startup
{
public void ConfigureServices(IServiceCollection services)
{
@sfmskywalker
sfmskywalker / Startup.cs
Last active Jul 21, 2018
Startup with custom configuration
View Startup.cs
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.DependencyInjection;
using OrchardCore.Environment.Shell;
namespace MultiTenantApp
{
You can’t perform that action at this time.