Skip to content

Commit 4ff2bc8

Browse files
committed
Stripped out everything not absoluately necessary
The goal of the `Host` project is to be as bare bones as possible. Real implementations will obviously have more complexity and ancillary libraries; our goal is not to provide a boilerplate project they can build off of. Instead, we're demonstrating the bare minimum needed to get **OnTopic Editor** working on an **ASP.NET Web Forms** site, with an emphasis on the code and libraries that are required. As a result, I've removed a lot of dependencies that e.g. **Visual Studio** sets up out-of-the-box, or which we inherited from reference sites. It turns out, we really don't need that much!
1 parent acd5186 commit 4ff2bc8

7 files changed

Lines changed: 2 additions & 232 deletions

File tree

OnTopic.Editor.Web.Host/OnTopic.Editor.Web.Host.csproj

Lines changed: 1 addition & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -50,74 +50,18 @@
5050
<Reference Include="OnTopic.Data.Caching, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
5151
<HintPath>..\packages\OnTopic.Data.Caching.4.0.0\lib\netstandard2.0\OnTopic.Data.Caching.dll</HintPath>
5252
</Reference>
53-
<Reference Include="Microsoft.CSharp" />
54-
<Reference Include="Microsoft.VisualStudio.Validation, Version=15.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
55-
<HintPath>..\packages\Microsoft.VisualStudio.Validation.15.5.31\lib\netstandard2.0\Microsoft.VisualStudio.Validation.dll</HintPath>
56-
</Reference>
5753
<Reference Include="OnTopic.Data.Sql, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
5854
<HintPath>..\packages\OnTopic.Data.Sql.4.0.0\lib\netstandard2.0\OnTopic.Data.Sql.dll</HintPath>
5955
</Reference>
6056
<Reference Include="OnTopic.Web, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
6157
<HintPath>..\packages\OnTopic.Web.4.0.0-alpha.2\lib\net48\OnTopic.Web.dll</HintPath>
6258
</Reference>
63-
<Reference Include="System.ComponentModel.Annotations, Version=4.2.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
64-
<HintPath>..\packages\System.ComponentModel.Annotations.4.6.0\lib\net461\System.ComponentModel.Annotations.dll</HintPath>
65-
</Reference>
66-
<Reference Include="System.ComponentModel.Composition" />
6759
<Reference Include="System.Data.SqlClient, Version=4.6.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
6860
<HintPath>..\packages\System.Data.SqlClient.4.7.0\lib\net461\System.Data.SqlClient.dll</HintPath>
6961
</Reference>
70-
<Reference Include="System.IO, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
71-
<HintPath>..\packages\System.IO.4.3.0\lib\net462\System.IO.dll</HintPath>
72-
<Private>True</Private>
73-
<Private>True</Private>
74-
</Reference>
75-
<Reference Include="System.Net.Http, Version=4.1.1.3, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
76-
<HintPath>..\packages\System.Net.Http.4.3.4\lib\net46\System.Net.Http.dll</HintPath>
77-
<Private>True</Private>
78-
<Private>True</Private>
79-
</Reference>
80-
<Reference Include="System.Runtime, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
81-
<HintPath>..\packages\System.Runtime.4.3.0\lib\net462\System.Runtime.dll</HintPath>
82-
<Private>True</Private>
83-
<Private>True</Private>
84-
</Reference>
85-
<Reference Include="System.Security.Cryptography.Algorithms, Version=4.2.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
86-
<HintPath>..\packages\System.Security.Cryptography.Algorithms.4.3.0\lib\net463\System.Security.Cryptography.Algorithms.dll</HintPath>
87-
<Private>True</Private>
88-
<Private>True</Private>
89-
</Reference>
90-
<Reference Include="System.Security.Cryptography.Encoding, Version=4.0.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
91-
<HintPath>..\packages\System.Security.Cryptography.Encoding.4.3.0\lib\net46\System.Security.Cryptography.Encoding.dll</HintPath>
92-
<Private>True</Private>
93-
<Private>True</Private>
94-
</Reference>
95-
<Reference Include="System.Security.Cryptography.Primitives, Version=4.0.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
96-
<HintPath>..\packages\System.Security.Cryptography.Primitives.4.3.0\lib\net46\System.Security.Cryptography.Primitives.dll</HintPath>
97-
<Private>True</Private>
98-
<Private>True</Private>
99-
</Reference>
100-
<Reference Include="System.Security.Cryptography.X509Certificates, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
101-
<HintPath>..\packages\System.Security.Cryptography.X509Certificates.4.3.0\lib\net461\System.Security.Cryptography.X509Certificates.dll</HintPath>
102-
<Private>True</Private>
103-
<Private>True</Private>
104-
</Reference>
105-
<Reference Include="System.Web.DynamicData" />
106-
<Reference Include="System.Web.Entity" />
107-
<Reference Include="System.Web.ApplicationServices" />
108-
<Reference Include="System.ComponentModel.DataAnnotations" />
10962
<Reference Include="System" />
110-
<Reference Include="System.Data" />
111-
<Reference Include="System.Core" />
112-
<Reference Include="System.Data.DataSetExtensions" />
113-
<Reference Include="System.Web.Extensions" />
114-
<Reference Include="System.Xml.Linq" />
115-
<Reference Include="System.Drawing" />
11663
<Reference Include="System.Web" />
117-
<Reference Include="System.Xml" />
11864
<Reference Include="System.Configuration" />
119-
<Reference Include="System.Web.Services" />
120-
<Reference Include="System.EnterpriseServices" />
12165
</ItemGroup>
12266
<ItemGroup>
12367
<Reference Include="Microsoft.CodeDom.Providers.DotNetCompilerPlatform">
@@ -146,9 +90,7 @@
14690
<DependentUpon>Web.config</DependentUpon>
14791
</None>
14892
</ItemGroup>
149-
<ItemGroup>
150-
<Folder Include="App_Data\" />
151-
</ItemGroup>
93+
<ItemGroup />
15294
<ItemGroup>
15395
<ProjectReference Include="..\OnTopic.Editor.Web\OnTopic.Editor.Web.csproj">
15496
<Project>{ed551277-df8a-4027-863f-7f8f72ca678c}</Project>

OnTopic.Editor.Web.Host/Web.Debug.config

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

OnTopic.Editor.Web.Host/Web.Release.config

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

OnTopic.Editor.Web.Host/Web.config

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,15 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<configuration>
33

4-
<appSettings>
5-
<add key="ValidationSettings:UnobtrusiveValidationMode" value="None" />
6-
</appSettings>
7-
84
<connectionStrings configSource="Configuration\ConnectionStrings.config"></connectionStrings>
95

106
<system.web>
117

12-
<compilation debug="true" targetFramework="4.8">
8+
<compilation debug="true">
139
<assemblies>
1410
<add assembly="netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51" />
1511
</assemblies>
1612
</compilation>
17-
<httpRuntime targetFramework="4.8" />
1813

1914
<pages pageBaseType="OnTopic.Web.TopicPage">
2015
<namespaces>
@@ -23,10 +18,6 @@
2318
<add namespace="OnTopic.Collections" />
2419
<add namespace="OnTopic.Web" />
2520
</namespaces>
26-
<controls>
27-
<add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
28-
<add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
29-
</controls>
3021
</pages>
3122

3223
</system.web>
@@ -37,13 +28,4 @@
3728
</compilers>
3829
</system.codedom>
3930

40-
<runtime>
41-
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
42-
<dependentAssembly>
43-
<assemblyIdentity name="System.ComponentModel.Annotations" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
44-
<bindingRedirect oldVersion="0.0.0.0-4.2.1.0" newVersion="4.2.1.0" />
45-
</dependentAssembly>
46-
</assemblyBinding>
47-
</runtime>
48-
4931
</configuration>
Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,9 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
33
<package id="Microsoft.CodeDom.Providers.DotNetCompilerPlatform" version="2.0.1" targetFramework="net48" />
4-
<package id="Microsoft.CSharp" version="4.6.0" targetFramework="net48" />
5-
<package id="Microsoft.VisualStudio.Validation" version="15.5.31" targetFramework="net48" />
64
<package id="OnTopic" version="4.0.0" targetFramework="net48" />
75
<package id="OnTopic.Data.Caching" version="4.0.0" targetFramework="net48" />
86
<package id="OnTopic.Data.Sql" version="4.0.0" targetFramework="net48" />
97
<package id="OnTopic.Web" version="4.0.0-alpha.2" targetFramework="net48" />
10-
<package id="System.ComponentModel.Annotations" version="4.6.0" targetFramework="net48" />
11-
<package id="System.Data.DataSetExtensions" version="4.5.0" targetFramework="net48" />
128
<package id="System.Data.SqlClient" version="4.7.0" targetFramework="net48" />
13-
<package id="System.IO" version="4.3.0" targetFramework="net48" />
14-
<package id="System.Net.Http" version="4.3.4" targetFramework="net48" />
15-
<package id="System.Runtime" version="4.3.0" targetFramework="net48" />
16-
<package id="System.Security.Cryptography.Algorithms" version="4.3.0" targetFramework="net48" />
17-
<package id="System.Security.Cryptography.Encoding" version="4.3.0" targetFramework="net48" />
18-
<package id="System.Security.Cryptography.Primitives" version="4.3.0" targetFramework="net48" />
19-
<package id="System.Security.Cryptography.X509Certificates" version="4.3.0" targetFramework="net48" />
209
</packages>

OnTopic.Editor.Web/OnTopic.Editor.Web.csproj

Lines changed: 0 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -47,77 +47,12 @@
4747
<WarningLevel>4</WarningLevel>
4848
</PropertyGroup>
4949
<ItemGroup>
50-
<Reference Include="Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
51-
<HintPath>..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.0\lib\net45\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.dll</HintPath>
52-
<Private>True</Private>
53-
</Reference>
54-
<Reference Include="Microsoft.CSharp" />
55-
<Reference Include="Microsoft.VisualStudio.Validation, Version=15.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
56-
<HintPath>..\packages\Microsoft.VisualStudio.Validation.15.5.31\lib\netstandard2.0\Microsoft.VisualStudio.Validation.dll</HintPath>
57-
<Private>True</Private>
58-
</Reference>
5950
<Reference Include="OnTopic, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
6051
<HintPath>..\packages\OnTopic.4.0.0\lib\netstandard2.0\OnTopic.dll</HintPath>
6152
</Reference>
62-
<Reference Include="OnTopic.Data.Caching, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
63-
<HintPath>..\packages\OnTopic.Data.Caching.4.0.0\lib\netstandard2.0\OnTopic.Data.Caching.dll</HintPath>
64-
</Reference>
65-
<Reference Include="OnTopic.Data.Sql, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
66-
<HintPath>..\packages\OnTopic.Data.Sql.4.0.0\lib\netstandard2.0\OnTopic.Data.Sql.dll</HintPath>
67-
</Reference>
6853
<Reference Include="OnTopic.Web, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
6954
<HintPath>..\packages\OnTopic.Web.4.0.0-alpha.2\lib\net48\OnTopic.Web.dll</HintPath>
7055
</Reference>
71-
<Reference Include="System.ComponentModel.Annotations, Version=4.2.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
72-
<HintPath>..\packages\System.ComponentModel.Annotations.4.6.0\lib\net461\System.ComponentModel.Annotations.dll</HintPath>
73-
</Reference>
74-
<Reference Include="System.ComponentModel.Composition" />
75-
<Reference Include="System.Data.DataSetExtensions" />
76-
<Reference Include="System.Data.SqlClient, Version=4.6.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
77-
<HintPath>..\packages\System.Data.SqlClient.4.7.0\lib\net461\System.Data.SqlClient.dll</HintPath>
78-
</Reference>
79-
<Reference Include="System.IO">
80-
<HintPath>..\packages\System.IO.4.3.0\lib\net462\System.IO.dll</HintPath>
81-
<Private>True</Private>
82-
</Reference>
83-
<Reference Include="System.Net.Http">
84-
<HintPath>..\packages\System.Net.Http.4.3.4\lib\net46\System.Net.Http.dll</HintPath>
85-
<Private>True</Private>
86-
</Reference>
87-
<Reference Include="System.Runtime">
88-
<HintPath>..\packages\System.Runtime.4.3.0\lib\net462\System.Runtime.dll</HintPath>
89-
<Private>True</Private>
90-
</Reference>
91-
<Reference Include="System.Security.Cryptography.Algorithms">
92-
<HintPath>..\packages\System.Security.Cryptography.Algorithms.4.3.0\lib\net463\System.Security.Cryptography.Algorithms.dll</HintPath>
93-
<Private>True</Private>
94-
</Reference>
95-
<Reference Include="System.Security.Cryptography.Encoding">
96-
<HintPath>..\packages\System.Security.Cryptography.Encoding.4.3.0\lib\net46\System.Security.Cryptography.Encoding.dll</HintPath>
97-
<Private>True</Private>
98-
</Reference>
99-
<Reference Include="System.Security.Cryptography.Primitives">
100-
<HintPath>..\packages\System.Security.Cryptography.Primitives.4.3.0\lib\net46\System.Security.Cryptography.Primitives.dll</HintPath>
101-
<Private>True</Private>
102-
</Reference>
103-
<Reference Include="System.Security.Cryptography.X509Certificates">
104-
<HintPath>..\packages\System.Security.Cryptography.X509Certificates.4.3.0\lib\net461\System.Security.Cryptography.X509Certificates.dll</HintPath>
105-
<Private>True</Private>
106-
</Reference>
107-
<Reference Include="System.Web.DynamicData" />
108-
<Reference Include="System.Web.Entity" />
109-
<Reference Include="System.Web.ApplicationServices" />
110-
<Reference Include="System.ComponentModel.DataAnnotations" />
111-
<Reference Include="System" />
112-
<Reference Include="System.Data" />
113-
<Reference Include="System.Web.Extensions" />
114-
<Reference Include="System.Drawing" />
115-
<Reference Include="System.Web" />
116-
<Reference Include="System.Xml" />
117-
<Reference Include="System.Configuration" />
118-
<Reference Include="System.Web.Services" />
119-
<Reference Include="System.EnterpriseServices" />
120-
<Reference Include="System.Xml.Linq" />
12156
</ItemGroup>
12257
<ItemGroup>
12358
<Content Include="Client\Sitemap.xml.aspx" />

OnTopic.Editor.Web/packages.config

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="ckeditor-full" version="4.5.3" targetFramework="net452" />
4-
<package id="Microsoft.CodeDom.Providers.DotNetCompilerPlatform" version="1.0.0" targetFramework="net452" />
5-
<package id="Microsoft.CSharp" version="4.6.0" targetFramework="net48" />
6-
<package id="Microsoft.Net.Compilers" version="1.0.0" targetFramework="net452" developmentDependency="true" />
7-
<package id="Microsoft.VisualStudio.Validation" version="15.5.31" targetFramework="net48" />
83
<package id="OnTopic" version="4.0.0" targetFramework="net48" />
9-
<package id="OnTopic.Data.Caching" version="4.0.0" targetFramework="net48" />
10-
<package id="OnTopic.Data.Sql" version="4.0.0" targetFramework="net48" />
114
<package id="OnTopic.Web" version="4.0.0-alpha.2" targetFramework="net48" />
12-
<package id="System.ComponentModel.Annotations" version="4.6.0" targetFramework="net48" />
13-
<package id="System.Data.DataSetExtensions" version="4.5.0" targetFramework="net48" />
14-
<package id="System.Data.SqlClient" version="4.7.0" targetFramework="net48" />
15-
<package id="System.IO" version="4.3.0" targetFramework="net48" />
16-
<package id="System.Net.Http" version="4.3.4" targetFramework="net48" />
17-
<package id="System.Runtime" version="4.3.0" targetFramework="net48" />
18-
<package id="System.Security.Cryptography.Algorithms" version="4.3.0" targetFramework="net48" />
19-
<package id="System.Security.Cryptography.Encoding" version="4.3.0" targetFramework="net48" />
20-
<package id="System.Security.Cryptography.Primitives" version="4.3.0" targetFramework="net48" />
21-
<package id="System.Security.Cryptography.X509Certificates" version="4.3.0" targetFramework="net48" />
225
</packages>

0 commit comments

Comments
 (0)