Skip to content

Commit 41963d6

Browse files
committed
Convert to project.json / .xproj files in preparation for .NET Core build. References #318
1 parent 956530a commit 41963d6

File tree

68 files changed

+754
-1455
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

68 files changed

+754
-1455
lines changed

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ src/React.Sample.Webpack/build
1212
*.generated.min.js
1313
src/React.Sample.Mvc6/wwwroot/js/Sample.js
1414
*.lock.json
15-
src/.vs
15+
.vs/
1616

1717
## Ignore Visual Studio temporary files, build results, and
1818
## files generated by popular Visual Studio add-ons.

src/Cassette.React/Cassette.React.csproj

-93
This file was deleted.

src/Cassette.React/Cassette.React.nutrans

-19
This file was deleted.
+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<PropertyGroup>
4+
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">14.0</VisualStudioVersion>
5+
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
6+
</PropertyGroup>
7+
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.Props" Condition="'$(VSToolsPath)' != ''" />
8+
<PropertyGroup Label="Globals">
9+
<ProjectGuid>b7d39e1d-6caa-4489-a03f-0c176402cfb2</ProjectGuid>
10+
<RootNamespace>Cassette.React</RootNamespace>
11+
<BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)'=='' ">.\obj</BaseIntermediateOutputPath>
12+
<OutputPath Condition="'$(OutputPath)'=='' ">.\bin\</OutputPath>
13+
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
14+
</PropertyGroup>
15+
<PropertyGroup>
16+
<SchemaVersion>2.0</SchemaVersion>
17+
</PropertyGroup>
18+
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.targets" Condition="'$(VSToolsPath)' != ''" />
19+
</Project>

src/Cassette.React/packages.config

-5
This file was deleted.

src/Cassette.React/project.json

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"version": "2.6.0-*",
3+
"title": "ReactJS.NET - Babel for Cassette",
4+
"authors": [ "Daniel Lo Nigro" ],
5+
"copyright": "Copyright 2014-Present Facebook, Inc",
6+
"description": "Allows you to transpile JavaScript via Babel using Cassette.",
7+
8+
"buildOptions": {
9+
"compile": {
10+
"includeFiles": [
11+
"../SharedAssemblyInfo.cs"
12+
]
13+
},
14+
"xmlDoc": true
15+
},
16+
17+
"packOptions": {
18+
"iconUrl": "http://facebook.github.io/react/img/logo_og.png",
19+
"licenseUrl": "https://github.com/reactjs/React.NET#licence",
20+
"owners": [ "Daniel Lo Nigro" ],
21+
"projectUrl": "http://reactjs.net/",
22+
"summary": "ReactJS and Babel tools for .NET",
23+
"tags": [ "asp.net", "mvc", "asp", "jquery", "javascript", "js", "react", "facebook", "reactjs", "babel", "cassette" ]
24+
},
25+
26+
"dependencies": {
27+
"Cassette": "2.4.2",
28+
"React.Core": {
29+
"target": "project"
30+
}
31+
},
32+
33+
"frameworks": {
34+
"net40": {
35+
}
36+
}
37+
}

src/React.AspNet/React.AspNet.xproj

+3-3
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@
88
<PropertyGroup Label="Globals">
99
<ProjectGuid>a7acdb56-5e43-40a6-92c9-2c52228e6074</ProjectGuid>
1010
<RootNamespace>React.AspNet</RootNamespace>
11-
<BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)'=='' ">..\artifacts\obj\$(MSBuildProjectName)</BaseIntermediateOutputPath>
12-
<OutputPath Condition="'$(OutputPath)'=='' ">..\..\bin\</OutputPath>
11+
<BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)'=='' ">.\obj</BaseIntermediateOutputPath>
12+
<OutputPath Condition="'$(OutputPath)'=='' ">.\bin\</OutputPath>
1313
<TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
1414
</PropertyGroup>
1515
<PropertyGroup>
1616
<SchemaVersion>2.0</SchemaVersion>
1717
</PropertyGroup>
1818
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.targets" Condition="'$(VSToolsPath)' != ''" />
19-
</Project>
19+
</Project>

src/React.AspNet/project.json

+7-6
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,19 @@
3333
"Microsoft.Extensions.DependencyInjection": "1.0.0",
3434
"React.Core": {
3535
"target": "project"
36-
},
37-
"VroomJs": "1.2.3"
36+
}
3837
},
3938
"frameworks": {
4039
"net451": {
41-
"bin": {
42-
"assembly": "../../bin/React.AspNet/bin/{configuration}/net451/React.AspNet.dll",
43-
"pdb": "../../bin/React.AspNet/bin/{configuration}/net451/React.AspNet.pdb"
44-
}
4540
}
4641
},
4742
"buildOptions": {
43+
"compile": {
44+
"includeFiles": [
45+
"../SharedAssemblyInfo.cs"
46+
]
47+
},
48+
"keyFile": "../key.snk",
4849
"xmlDoc": true
4950
}
5051
}

src/React.Core/JavaScriptEngineFactory.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -103,11 +103,11 @@ protected virtual IJsPool CreatePool()
103103
protected virtual void InitialiseEngine(IJsEngine engine)
104104
{
105105
var thisAssembly = typeof(ReactEnvironment).Assembly;
106-
engine.ExecuteResource("React.Resources.shims.js", thisAssembly);
106+
engine.ExecuteResource("React.Core.Resources.shims.js", thisAssembly);
107107
if (_config.LoadReact)
108108
{
109109
// TODO: Add option to choose whether to load dev vs prod version of React.
110-
engine.ExecuteResource("React.Resources.react.generated.js", thisAssembly);
110+
engine.ExecuteResource("React.Core.Resources.react.generated.js", thisAssembly);
111111
}
112112

113113
LoadUserScripts(engine);

0 commit comments

Comments
 (0)