Enable Platform-Specific Resourcing (ditch the #defs)
See original GitHub issueNow that VS2017 is out (#92), it might be worth exploring a more structured/discoverable way to introduce and locate platform-specific resources and dependencies.
One thought is to use convention by default, and do a test for an assembly that has the same name as the current assembly + Platforms
+ moniker. So, in the case of ExtendedXmlSerializer
:
ExtendedXmlSerializer.Platforms.NetCore
<== .NET CoreExtendedXmlSerializer.Platforms.NetFramework
<== .NET Framework
Additionally, once the assembly has been resolved and located, a simple call to register it with the current (internal) container (enabling the use of an ICompositionRoot) would be a very straight forward task.
Advantages of this approach:
- No more #defines (!)
- Clean separation of platform concerns
Disadvantages:
- Two more assemblies to account for in our solution and for NuGet.
- ? (Additional feedback welcomed)
Issue Analytics
- State:
- Created 6 years ago
- Comments:22 (22 by maintainers)
Top Results From Across the Web
Manage resource lifecycle | Terraform
Lifecycle arguments help control the flow of your Terraform operations by creating custom rules for resource creation and destruction.
Read more >Manage Consul with Kubernetes custom resource ...
Learn how to work with config entries as Custom Resource Definitions (CRDs); Download the latest helm chart; Install or upgrade Consul (with Helm...
Read more >Revised Definition of “Waters of the United States”
Waters considered “jurisdictional by rule” included: (1) traditional navigable waters; (2) interstate waters, including interstate wetlands; (3) ...
Read more >RCW 49.46.300: Transportation network companies ...
(j) "Driver platform" means the driver-facing application dispatch system software or any online-enabled application service, website, or system, used by a ...
Read more >What is Zero Trust?
Zero Trust refers to a security approach that assumes no user is trustworthy. Adopting this concept with zero trust vendors protects against cyber...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ok it sounds good.
OK. 😃 I think the way to go for now is to do one project to multiple frameworks, like v1.0, and then for v3.0 we can revisit this, maybe for #107.
Since there is only one
#if
this isn’t a big deal for 2.0, but I think for .NET Standard 1.x it will require many more#if
’s, and that will be ugly, so having separate projects will be better then.Sound good?