Skip to content

Releases: giraffe-fsharp/Giraffe

0.1.0-beta-510

19 Dec 17:09
Compare
Choose a tag to compare
0.1.0-beta-510 Pre-release
Pre-release

Improvements

  • Explicitly set the encoding to UTF-8 when reading the HTTP body during ReadBodyFromRequestAsync

New features

  • Added the html http handler which can be used to return a text/html response by passing in the html content as a string variable

0.1.0-beta-500

12 Dec 16:01
Compare
Choose a tag to compare
0.1.0-beta-500 Pre-release
Pre-release

New features

  • Added a new overload for GetLogger of the HttpContext extension methods, which allows one to pass in a categoryName string in order to initialise a new logger: let logger = ctx.GetLogger "categoryName".
  • BindFormAsync, BindQueryString and BindModelAsync accept an additional optional parameter for CultureInfo.

Breaking changes

  • Removed Giraffe.Tasks from the Giraffe NuGet package and added a new dependency on the newly created Giraffe.Tasks NuGet package. You can use the Giraffe.Tasks NuGet package from non ASP.NET Core projects now as well.

0.1.0-beta-400

04 Dec 22:02
Compare
Choose a tag to compare
0.1.0-beta-400 Pre-release
Pre-release

New features

  • Added HTTP status code helper functions.
  • Added defaultSerializeJson and defaultDeserializeJson methods.
  • Auto opened default Giraffe modules so that the core functionality can be entirely consumed through a single open Giraffe statement.
  • The functionality from Giraffe.Razor.Middleware and Giraffe.Razor.HttpHandlers can be both consumed through a single open Giraffe.Razor now.

Bug fixes

  • Changed the base tag from the XmlViewEngine from a regular tag to a voidTag to comply with the HTML spec.

Breaking changes

  • Renamed all async methods by appending Async at the end of the method in order to comply with the general .NET naming convention
    • readFileAsString --> readFileAsStringAsync
    • ctx.ReadBodyFromRequest --> ctx.ReadBodyFromRequestAsync
    • ctx.BindJson --> ctx.BindJsonAsync
    • ctx.BindXml --> ctx.BindXmlAsync
    • ctx.BindForm --> ctx.BindFormAsync
    • ctx.BindModel --> ctx.BindModelAsync
    • ctx.WriteJson --> ctx.WriteJsonAsync
    • ctx.WriteXml --> ctx.WriteXmlAsync
    • ctx.WriteText --> ctx.WriteTextAsync
    • ctx.RenderHtml --> ctx.RenderHtmlAsync
    • ctx.ReturnHtmlFile --> ctx.ReturnHtmlFileAsync
  • Renamed Giraffe.DotLiquid.HttpHandlers module to Giraffe.DotLiquid

0.1.0-beta-310

30 Nov 12:18
Compare
Choose a tag to compare
0.1.0-beta-310 Pre-release
Pre-release

New features

  • Added portRoute http handler to filter an incoming request based on the port

Breaking changes

  • The GET, POST, PUT and DELETE http handlers of the TokenRouter.fs have changed to accept a list of http handlers now.

Bug fixes

  • TokenRouter fringe case not being identified before (see #150)

0.1.0-beta-300

18 Nov 07:36
Compare
Choose a tag to compare
0.1.0-beta-300 Pre-release
Pre-release

New features

  • Added requiresAuthPolicy http handler
  • Added RenderHtml and ReturnHtmlFile extension methods to the HttpContext object
  • Added customJson http handler, which allows users to define a custom json handler (with custom serialization settings)
  • Added overloads to BindJson and BindModel where a user can pass in a custom JsonSerializerSettings object

Breaking changes

  • Changed the default json serializer to use camel case for serialization (this change prevents users from being able to change the default serializer through the JsonConvert.DefaultSettings object - use customJson instead if customization is required)
  • Changed the serializeJson, deserializeJson methods to accept an aditional parameter of type JsonSerializerSettings

Bug fixes and improvements

  • Automatically URL decoding of string values when using routef
  • Fixed an inference bug with routef by replacing the format parameter of the tryMatchInput method and the path parameter of the routef and routeCif methods from StringFormat to PrintFormat
  • Changed the implementation of ctx.BindJson<'T>() for better performance and which aims to fix an Azure bug with Kestrel (#136)
  • Fixed a bug with routeBind (#129)
  • Improved the htmlFile http handler by allowing the filePath parameter to be either rooted or relative to the ContentRootPath

0.1.0-beta-200

29 Oct 17:36
Compare
Choose a tag to compare
0.1.0-beta-200 Pre-release
Pre-release
  • Added three additional HttpContext extension methods in the Giraffe.HttpContextExtensions module: WriteJson, WriteXml and WriteText. These three methods can be used for direct HttpReponse writing from within a custom handler without having to sub-call the json, xml or text http handlers.
  • Changed the UseGiraffeErrorHandler method to return an IApplicationBuilder now. This change allows middleware chaining. This is a breaking change and you'll either have to chain middleware or append an |> ignore in your application set up.

0.1.0-beta-110

25 Oct 07:11
Compare
Choose a tag to compare
0.1.0-beta-110 Pre-release
Pre-release

Added the Giraffe.TokenRouter module for speed improved route handling.

0.1.0-beta-102

19 Oct 13:23
Compare
Choose a tag to compare
0.1.0-beta-102 Pre-release
Pre-release

Improved the routeBind http handler to give users more flexibility in mapping routes to HTTP requests (see #110).

0.1.0-beta-101

10 Oct 15:42
Compare
Choose a tag to compare
0.1.0-beta-101 Pre-release
Pre-release
  • Fixed bug in connection with the ExceptionHandlerMiddleware (see #106)
  • Added CORS settings for localhost to the default giraffe-template

0.1.0-beta-100

28 Aug 10:23
Compare
Choose a tag to compare
0.1.0-beta-100 Pre-release
Pre-release

Updated Giraffe to .NET Standard 2.0

Attention, this release updated all Giraffe NuGet packages to net461 and netstandard2.0!

You will have to upgrade your ASP.NET Core application to either full .NET framework 461 or to a .NET Core app 2.0.

There were a few minor breaking changes in ASP.NET Core 2.0 which also affected Giraffe. I do not intend to keep maintaining a 1.x version any longer unless there's a very compelling reason. General advice is to upgrade all .NET Core web applications to 2.0.