Open
Description
Type of issue
Missing information
Description
This is the example given
#r "nuget: Newtonsoft.Json"
open Newtonsoft.Json
let data = {| Name = "Don Syme"; Occupation = "F# Creator" |}
JsonConvert.SerializeObject(data)
That’s too simplistic. If you add this example, you can tell more of the story:
#r "nuget: Mono.Posix.NETStandard"
open Mono.Unix.Native
and even more:
#r "nuget: NaturalStringExtensions"
let comparator a b = System.NaturalStringComparer().Compare(a, b)
These examples would help to avoid mystification in cases where the names in the #r
and the usage differ.
Page URL
https://learn.microsoft.com/en-us/dotnet/fsharp/tools/fsharp-interactive/
Content source URL
https://github.com/dotnet/docs/blob/main/docs/fsharp/tools/fsharp-interactive/index.md
Document Version Independent Id
400ddb93-a841-963b-58cc-21f506b13b61
Article author
cartermp
Metadata
- ID: db36a87c-0928-52ce-38f3-1555e450cce1
- Product: dotnet-fsharp