Skip to content

Commit c4421f5

Browse files
committed
Moved the tsconfig file(s) out of the wwwroot folder.
Added support for two tsconfig files. One that includes a sourcemap file for Debug builds and another one that skips the sourcemap for Release builds. Marked the content of wwwroot/ts/* as "content" with the .csproj meaning. This fixes typescript sourcemap issues.
1 parent e930f50 commit c4421f5

File tree

9 files changed

+81
-44
lines changed

9 files changed

+81
-44
lines changed

ChartJs.Blazor.Tests/ChartJs.Blazor.Tests.csproj

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,7 @@
1515
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1616
</PackageReference>
1717
<PackageReference Include="coverlet.collector" Version="1.0.1" />
18-
</ItemGroup>
19-
20-
<ItemGroup>
21-
<ProjectReference Include="..\src\ChartJs.Blazor\ChartJs.Blazor.csproj" />
18+
<PackageReference Include="ChartJs.Blazor" Version="2.0.0-preview13" />
2219
</ItemGroup>
2320

2421
</Project>

ChartJs.Blazor.sln

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,19 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{08E01108-AF6
77
EndProject
88
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "samples", "samples", "{5474F748-8E27-4FD6-AD9D-1087578ED4D7}"
99
EndProject
10-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ChartJs.Blazor", "src\ChartJs.Blazor\ChartJs.Blazor.csproj", "{1990A3D7-7B00-469F-BC97-F614393F7A52}"
10+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChartJs.Blazor", "src\ChartJs.Blazor\ChartJs.Blazor.csproj", "{1990A3D7-7B00-469F-BC97-F614393F7A52}"
1111
EndProject
1212
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ClientSide", "ClientSide", "{474E0BD0-B8C0-4A00-9B05-B1B33F3B7C94}"
1313
EndProject
1414
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ServerSide", "ServerSide", "{A9B59800-FB77-43FE-BF42-BE991D9FDBF5}"
1515
EndProject
1616
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Shared", "Shared", "{99703BE7-7A02-454D-8066-87BBEBA039BD}"
1717
EndProject
18-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ChartJs.Blazor.Sample.Shared", "samples\Shared\ChartJs.Blazor.Sample.Shared\ChartJs.Blazor.Sample.Shared.csproj", "{3FB87C6F-5C21-4095-AC64-35AE6299B88F}"
18+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChartJs.Blazor.Sample.Shared", "samples\Shared\ChartJs.Blazor.Sample.Shared\ChartJs.Blazor.Sample.Shared.csproj", "{3FB87C6F-5C21-4095-AC64-35AE6299B88F}"
1919
EndProject
20-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ChartJs.Blazor.Sample.ServerSide", "samples\ServerSide\ChartJs.Blazor.Sample.ServerSide\ChartJs.Blazor.Sample.ServerSide.csproj", "{D547792A-5B2C-4FAF-93AA-71BAA9BF845C}"
20+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChartJs.Blazor.Sample.ServerSide", "samples\ServerSide\ChartJs.Blazor.Sample.ServerSide\ChartJs.Blazor.Sample.ServerSide.csproj", "{D547792A-5B2C-4FAF-93AA-71BAA9BF845C}"
2121
EndProject
22-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ChartJs.Blazor.Sample.ClientSide", "samples\ClientSide\ChartJs.Blazor.Sample.ClientSide\ChartJs.Blazor.Sample.ClientSide.csproj", "{153F4719-305A-4AD0-975A-91ABD9935F87}"
22+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChartJs.Blazor.Sample.ClientSide", "samples\ClientSide\ChartJs.Blazor.Sample.ClientSide\ChartJs.Blazor.Sample.ClientSide.csproj", "{153F4719-305A-4AD0-975A-91ABD9935F87}"
2323
EndProject
2424
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChartJs.Blazor.Tests", "ChartJs.Blazor.Tests\ChartJs.Blazor.Tests.csproj", "{135A9451-FC82-48B4-89F6-3CBF5312B2C2}"
2525
EndProject

samples/ClientSide/ChartJs.Blazor.Sample.ClientSide/ChartJs.Blazor.Sample.ClientSide.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@
1111
<PackageReference Include="Microsoft.AspNetCore.Blazor.HttpClient" Version="3.1.0-preview4.19579.2" />
1212
<PackageReference Include="Microsoft.AspNetCore.Blazor.DevServer" Version="3.1.0-preview4.19579.2" PrivateAssets="all" />
1313
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
14+
<PackageReference Include="ChartJs.Blazor" Version="2.0.0-preview20" />
1415
</ItemGroup>
1516

1617
<ItemGroup>
17-
<ProjectReference Include="..\..\..\src\ChartJs.Blazor\ChartJs.Blazor.csproj" />
1818
<ProjectReference Include="..\..\Shared\ChartJs.Blazor.Sample.Shared\ChartJs.Blazor.Sample.Shared.csproj" />
1919
</ItemGroup>
2020

samples/ServerSide/ChartJs.Blazor.Sample.ServerSide/ChartJs.Blazor.Sample.ServerSide.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@
55
</PropertyGroup>
66

77
<ItemGroup>
8-
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="3.1.0" />
8+
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="3.1.5" />
9+
<PackageReference Include="ChartJs.Blazor" Version="2.0.0-preview20" />
910
</ItemGroup>
1011

1112
<ItemGroup>
12-
<ProjectReference Include="..\..\..\src\ChartJs.Blazor\ChartJs.Blazor.csproj" />
1313
<ProjectReference Include="..\..\Shared\ChartJs.Blazor.Sample.Shared\ChartJs.Blazor.Sample.Shared.csproj" />
1414
</ItemGroup>
1515

samples/Shared/ChartJs.Blazor.Sample.Shared/ChartJs.Blazor.Sample.Shared.csproj

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
</PropertyGroup>
77

88
<ItemGroup>
9-
<ProjectReference Include="..\..\..\src\ChartJs.Blazor\ChartJs.Blazor.csproj" />
9+
<PackageReference Include="ChartJs.Blazor" Version="2.0.0-preview20" />
1010
</ItemGroup>
11-
12-
</Project>
11+
</Project>

src/ChartJs.Blazor/ChartJs.Blazor.csproj

Lines changed: 29 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@
1010
<Company>Marius Muntean</Company>
1111
<Authors>Marius Muntean</Authors>
1212
<Description>ChartJs charts for Blazor.
13-
Compatible with client-side and server-side Blazor applications.</Description>
13+
Compatible with client-side and server-side Blazor applications.
14+
</Description>
1415
<RepositoryUrl>https://github.com/mariusmuntean/ChartJs.Blazor</RepositoryUrl>
1516
<PackageProjectUrl>https://github.com/mariusmuntean/ChartJs.Blazor</PackageProjectUrl>
1617
<PackageTags>ChartJS Blazor ASP.Net Core wasm</PackageTags>
@@ -19,37 +20,47 @@ Compatible with client-side and server-side Blazor applications.</Description>
1920
<AssemblyName>ChartJs.Blazor</AssemblyName>
2021
<RootNamespace>ChartJs.Blazor</RootNamespace>
2122
<GeneratePackageOnBuild>false</GeneratePackageOnBuild>
22-
<Version>1.1.0</Version>
23-
<AssemblyVersion>1.1.0.0</AssemblyVersion>
24-
<FileVersion>1.1.0.0</FileVersion>
23+
<Version>2.0.0</Version>
24+
<AssemblyVersion>2.0.0.0</AssemblyVersion>
25+
<FileVersion>2.0.0.0</FileVersion>
2526
<PackageLicenseExpression>MIT</PackageLicenseExpression>
26-
<PackageVersion>1.1.0</PackageVersion>
27+
<PackageVersion>2.0.0-preview20</PackageVersion>
2728
</PropertyGroup>
2829

2930
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
3031
<DocumentationFile>.\ChartJs.Blazor.xml</DocumentationFile>
3132
</PropertyGroup>
33+
<ItemGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
34+
<Content Remove="tsbuild/debug/tsconfig.json" />
35+
</ItemGroup>
36+
37+
<ItemGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
38+
<Content Remove="tsbuild/release/tsconfig.json" />
39+
<Content Include="wwwroot/ts/**/*">
40+
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
41+
</Content>
42+
</ItemGroup>
3243

3344
<ItemGroup>
34-
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="3.1.4" />
45+
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="3.1.5" />
3546
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
3647
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
37-
<PackageReference Include="Microsoft.TypeScript.MSBuild" Version="3.9.2">
48+
<PackageReference Include="Microsoft.TypeScript.MSBuild" Version="3.9.5">
3849
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
3950
<PrivateAssets>all</PrivateAssets>
4051
</PackageReference>
4152
</ItemGroup>
4253

43-
<ItemGroup>
44-
<None Update="ChartJS\BarChart\Axes\ExtendedCartesianAxes.tt">
45-
<Generator>TextTemplatingFileGenerator</Generator>
46-
<LastGenOutput>ExtendedCartesianAxes.cs</LastGenOutput>
47-
</None>
48-
</ItemGroup>
54+
<ItemGroup>
55+
<None Update="ChartJS\BarChart\Axes\ExtendedCartesianAxes.tt">
56+
<Generator>TextTemplatingFileGenerator</Generator>
57+
<LastGenOutput>ExtendedCartesianAxes.cs</LastGenOutput>
58+
</None>
59+
</ItemGroup>
4960

50-
<ItemGroup>
51-
<Compile Update="ChartJS\BarChart\Axes\ExtendedCartesianAxes.cs">
52-
<DependentUpon>ExtendedCartesianAxes.tt</DependentUpon>
53-
</Compile>
54-
</ItemGroup>
61+
<ItemGroup>
62+
<Compile Update="ChartJS\BarChart\Axes\ExtendedCartesianAxes.cs">
63+
<DependentUpon>ExtendedCartesianAxes.tt</DependentUpon>
64+
</Compile>
65+
</ItemGroup>
5566
</Project>
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"compilerOptions": {
3+
"allowJs": true,
4+
"module": "none",
5+
"target": "es2018",
6+
"lib": [
7+
"dom",
8+
"es2018"
9+
],
10+
"outFile": "../../wwwroot/ChartJsBlazorInterop.js",
11+
"sourceMap": true,
12+
"typeRoots": [
13+
"../../wwwroot/ts/types/"
14+
],
15+
"alwaysStrict": true
16+
},
17+
"include": [
18+
"../../wwwroot/ts/*.ts"
19+
],
20+
"compileOnSave": true
21+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"compilerOptions": {
3+
"allowJs": true,
4+
"module": "none",
5+
"target": "es2018",
6+
"lib": [
7+
"dom",
8+
"es2018"
9+
],
10+
"outFile": "../../wwwroot/ChartJsBlazorInterop.js",
11+
"sourceMap": false,
12+
"typeRoots": [
13+
"../../wwwroot/ts/types/"
14+
],
15+
"alwaysStrict": true
16+
},
17+
"include": [
18+
"../../wwwroot/ts/*.ts"
19+
],
20+
"compileOnSave": true
21+
}

src/ChartJs.Blazor/wwwroot/tsconfig.json

Lines changed: 0 additions & 12 deletions
This file was deleted.

0 commit comments

Comments
 (0)