Browse Source

Merge branch 'master' of github.com:SebastianStehle/PinkParrot

pull/1/head
Sebastian 9 years ago
parent
commit
1b59a310e5
  1. 12
      src/Squidex/Startup.cs
  2. 2
      src/Squidex/package.json

12
src/Squidex/Startup.cs

@ -7,6 +7,7 @@
// ========================================================================== // ==========================================================================
using System; using System;
using System.IO;
using Autofac; using Autofac;
using Autofac.Extensions.DependencyInjection; using Autofac.Extensions.DependencyInjection;
using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Builder;
@ -152,15 +153,20 @@ namespace Squidex
app.UseWebpackProxy(); app.UseWebpackProxy();
app.Use((context, next) => { app.Use((context, next) => {
context.Request.Path = new PathString("/index.html"); if (!Path.HasExtension(context.Request.Path.Value))
{
context.Request.Path = new PathString("/index.html");
}
return next(); return next();
}); });
} }
else else
{ {
app.Use((context, next) => { app.Use((context, next) => {
context.Request.Path = new PathString("/build/index.html"); if (!Path.HasExtension(context.Request.Path.Value))
{
context.Request.Path = new PathString("/build/index.html");
}
return next(); return next();
}); });

2
src/Squidex/package.json

@ -10,7 +10,7 @@
"test:clean": "rimraf _test-output", "test:clean": "rimraf _test-output",
"dev": "cpx node_modules/oidc-client/dist/oidc-client.min.js wwwroot/scripts/ & webpack-dev-server --inline --hot --port 3000", "dev": "cpx node_modules/oidc-client/dist/oidc-client.min.js wwwroot/scripts/ & webpack-dev-server --inline --hot --port 3000",
"build": "webpack --config app-config/webpack.prod.js --bail", "build": "webpack --config app-config/webpack.prod.js --bail",
"build:copy": "cpx node_modules/oidc-client/dist/oidc-client.min.js", "build:copy": "cpx node_modules/oidc-client/dist/oidc-client.min.js wwwroot/scripts/",
"build:clean": "rimraf wwwroot/build" "build:clean": "rimraf wwwroot/build"
}, },
"dependencies": { "dependencies": {

Loading…
Cancel
Save