FSharp.Configuration


FSharp.Configuration

The FSharp.Configuration project contains type providers for the configuration of .NET projects.

The library can be installed from NuGet:
PM> Install-Package FSharp.Configuration

Example

This example demonstrates the use of the AppSettings type provider:

 1: 
 2: 
 3: 
 4: 
 5: 
 6: 
 7: 
 8: 
 9: 
10: 
11: 
// reference the type provider dll
#r "FSharp.Configuration.dll"
#r "System.Configuration.dll"
open FSharp.Configuration

// Let the type provider do it's work
type Settings = AppSettings<"app.config">

Settings.ConfigFileName
Settings.Test2
val it : string = "Some Test Value 5"

alt text

Contributing and copyright

The project is hosted on GitHub where you can report issues, fork the project and submit pull requests. If you're adding new public API, please also consider adding samples that can be turned into a documentation. You might also want to read library design notes to understand how it works.

The library is available under Public Domain license, which allows modification and redistribution for both commercial and non-commercial purposes. For more information see the License file in the GitHub repository.

Multiple items
namespace FSharp

--------------------
namespace Microsoft.FSharp
namespace FSharp.Configuration
type Settings = AppSettings<...>

Full name: Index.Settings
type AppSettings

Full name: FSharp.Configuration.AppSettings
property AppSettings<...>.ConfigFileName: string


Returns the Filename
property AppSettings<...>.Test2: string


Returns the value from app.config with key test2
Fork me on GitHub