Skip to content

Commit 5196c1c

Browse files
committed
Upgrade ASP.NET 5 to beta 7
1 parent cd4d004 commit 5196c1c

File tree

9 files changed

+50
-23
lines changed

9 files changed

+50
-23
lines changed

build.proj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ of patent rights can be found in the PATENTS file in the same directory.
3333
<PackageAssemblies Include="React.MSBuild" />
3434
<PackageAssemblies Include="React.Owin" />
3535
<PackageAssembliesAspNet5 Include="React.AspNet" />
36-
<AspNet5ProjectJson Include="src/**/project.json" />
36+
<AspNet5ProjectJson Include="src/React.AspNet/project.json" />
37+
<AspNet5ProjectJson Include="src/React.Sample.Mvc6/project.json" />
3738
</ItemGroup>
3839

3940
<Import Project="src/React.tasks.proj" />

src/React.AspNet/HtmlHelperExtensions.cs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
using IHtmlHelper = System.Web.Mvc.HtmlHelper;
1717
#else
1818
using Microsoft.AspNet.Mvc.Rendering;
19-
using IHtmlString = Microsoft.AspNet.Mvc.Rendering.HtmlString;
19+
using IHtmlString = Microsoft.AspNet.Html.Abstractions.IHtmlContent;
2020
#endif
2121

2222
#if LEGACYASPNET
@@ -118,7 +118,11 @@ public static IHtmlString ReactWithInit<T>(
118118
var html = reactComponent.RenderHtml(clientOnly);
119119
var script = new TagBuilder("script")
120120
{
121+
#if LEGACYASPNET
121122
InnerHtml = reactComponent.RenderJavaScript()
123+
#else
124+
InnerHtml = new HtmlString(reactComponent.RenderJavaScript())
125+
#endif
122126
};
123127
return new HtmlString(html + System.Environment.NewLine + script.ToString());
124128
}
@@ -131,11 +135,19 @@ public static IHtmlString ReactWithInit<T>(
131135
public static IHtmlString ReactInitJavaScript(this IHtmlHelper htmlHelper)
132136
{
133137
var script = Environment.GetInitJavaScript();
138+
#if LEGACYASPNET
134139
var tag = new TagBuilder("script")
135140
{
136141
InnerHtml = script
137142
};
138143
return new HtmlString(tag.ToString());
144+
#else
145+
var tag = new TagBuilder("script")
146+
{
147+
InnerHtml = new HtmlString(script)
148+
};
149+
return tag;
150+
#endif
139151
}
140152
}
141153
}

src/React.AspNet/React.AspNet.xproj

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@
1515
</PropertyGroup>
1616
<PropertyGroup>
1717
<SchemaVersion>2.0</SchemaVersion>
18+
<TypeScriptCompileBlocked>True</TypeScriptCompileBlocked>
19+
</PropertyGroup>
20+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
21+
<ProduceOutputsOnBuild>True</ProduceOutputsOnBuild>
22+
</PropertyGroup>
23+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
24+
<ProduceOutputsOnBuild>True</ProduceOutputsOnBuild>
1825
</PropertyGroup>
1926
<ItemGroup>
2027
<ProjectReference Include="..\React.Core\React.Core.csproj" />

src/React.AspNet/ReactBuilderExtensions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
using System;
1111
using Microsoft.AspNet.Builder;
1212
using Microsoft.AspNet.Hosting;
13+
using Microsoft.Dnx.Runtime;
1314
using Microsoft.Framework.DependencyInjection;
14-
using Microsoft.Framework.Runtime;
1515
using React.Exceptions;
1616
using React.TinyIoC;
1717

src/React.AspNet/project.json

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@
1515
}
1616
},
1717
"dependencies": {
18-
"Microsoft.Framework.DependencyInjection": "1.0.0-beta6",
19-
"Microsoft.AspNet.Mvc.Core": "6.0.0-beta6",
20-
"Microsoft.AspNet.StaticFiles": "1.0.0-beta6",
21-
"Microsoft.AspNet.FileProviders.Physical": "1.0.0-beta6",
22-
"Microsoft.AspNet.Mvc.ViewFeatures": "6.0.0-beta6",
18+
"Microsoft.Framework.DependencyInjection": "1.0.0-beta7",
19+
"Microsoft.AspNet.Mvc.Core": "6.0.0-beta7",
20+
"Microsoft.AspNet.StaticFiles": "1.0.0-beta7",
21+
"Microsoft.AspNet.FileProviders.Physical": "1.0.0-beta7",
22+
"Microsoft.AspNet.Mvc.ViewFeatures": "6.0.0-beta7",
2323
"React.Core": "",
2424
"JavaScriptEngineSwitcher.Core": "1.2.4.0"
2525
},
@@ -28,6 +28,11 @@
2828
},
2929

3030
"authors": [ "Daniel Lo Nigro" ],
31+
"owners": [ "Daniel Lo Nigro" ],
32+
"licenseUrl": "https://github.com/reactjs/React.NET#licence",
33+
"iconUrl": "http://facebook.github.io/react/img/logo_og.png",
34+
"copyright": "Copyright 2014-2015 Facebook, Inc",
35+
"title": "ReactJS.NET (MVC 6)",
3136
"description": "ReactJS tools for ASP.NET 5, including ASP.NET MVC 6. Please refer to project site (http://reactjs.net/) for full installation instructions, usage examples and sample code",
3237
"tags": [ "asp.net", "mvc", "asp", "javascript", "js", "react", "facebook", "reactjs", "vnext" ],
3338
"projectUrl": "http://reactjs.net/"

src/React.Sample.Mvc6/React.Sample.Mvc6.xproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,11 @@
1313
<PropertyGroup>
1414
<SchemaVersion>2.0</SchemaVersion>
1515
<DevelopmentServerPort>3044</DevelopmentServerPort>
16+
<TypeScriptCompileBlocked>True</TypeScriptCompileBlocked>
1617
</PropertyGroup>
1718
<ProjectExtensions>
1819
<VisualStudio>
19-
<UserProperties bower_1json__JSONSchema="http://json.schemastore.org/bower" package_1json__JSONSchema="http://json.schemastore.org/package" />
20+
<UserProperties />
2021
</VisualStudio>
2122
</ProjectExtensions>
2223
<Import Project="$(VSToolsPath)\DNX\Microsoft.DNX.Props" />

src/React.Sample.Mvc6/Startup.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,13 @@
77
* of patent rights can be found in the PATENTS file in the same directory.
88
*/
99

10-
using System;
1110
using Microsoft.AspNet.Builder;
12-
using Microsoft.AspNet.Diagnostics;
1311
using Microsoft.AspNet.Hosting;
12+
using Microsoft.Dnx.Runtime;
1413
using Microsoft.Framework.Configuration;
1514
using Microsoft.Framework.DependencyInjection;
1615
using Microsoft.Framework.Logging;
1716
using React.AspNet;
18-
using Microsoft.Framework.Runtime;
1917

2018
namespace React.Sample.Mvc6
2119
{

src/React.Sample.Mvc6/project.json

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22
"webroot": "wwwroot",
33
"version": "1.5.5-*",
44
"dependencies": {
5-
"Microsoft.AspNet.Mvc": "6.0.0-beta6",
6-
"Microsoft.AspNet.Diagnostics": "1.0.0-beta6",
7-
"Microsoft.AspNet.Server.IIS": "1.0.0-beta6",
8-
"Microsoft.AspNet.Server.WebListener": "1.0.0-beta6",
9-
"Microsoft.AspNet.StaticFiles": "1.0.0-beta6",
10-
"Microsoft.Framework.Configuration.EnvironmentVariables": "1.0.0-beta6",
11-
"Microsoft.Framework.Configuration.Json": "1.0.0-beta6",
12-
"Microsoft.Framework.Logging": "1.0.0-beta6",
13-
"Microsoft.Framework.Logging.Console": "1.0.0-beta6",
5+
"Microsoft.AspNet.Mvc": "6.0.0-beta7",
6+
"Microsoft.AspNet.Diagnostics": "1.0.0-beta7",
7+
"Microsoft.AspNet.Server.IIS": "1.0.0-beta7",
8+
"Microsoft.AspNet.Server.WebListener": "1.0.0-beta7",
9+
"Microsoft.AspNet.StaticFiles": "1.0.0-beta7",
10+
"Microsoft.Framework.Configuration.EnvironmentVariables": "1.0.0-beta7",
11+
"Microsoft.Framework.Configuration.Json": "1.0.0-beta7",
12+
"Microsoft.Framework.Logging": "1.0.0-beta7",
13+
"Microsoft.Framework.Logging.Console": "1.0.0-beta7",
1414
"React.AspNet": "",
1515
"React.Core": "",
1616
"JavaScriptEngineSwitcher.V8": "1.2.4.0",

src/global.json

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
{
22
"sources": [
33
"wrap"
4-
]
5-
}
4+
],
5+
"sdk": {
6+
"version": "1.0.0-beta7"
7+
}
8+
}

0 commit comments

Comments
 (0)