6

SAFE Stack 3 is now live!

 3 years ago
source link: https://www.compositional-it.com/news-blog/safe-stack-3-is-now-live/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

SAFE Stack 3 is now live!



Isaac gives us a quick rundown of the cool new features in the latest iteration of SAFE Stack!



By Isaac Abraham

Posted: June 29, 2021

Categorised: Uncategorized

Great news! The SAFE team are excited to announce that as of today we've launched SAFE Stack 3 - the best way to develop functional-first web applications. For those that don't know about SAFE, it's a web stack that runs on top of both JavaScript and .NET runtimes, with a unified F# layer over the top - meaning you can take advantage of .NET NuGet packages on the server, and the huge JS ecosystem on the web, but still benefit from using a single language whilst taking advantage of F#'s type safety and power features both on the server and within the browser.

I wanted to (briefly) give you an overview of what's new in SAFE 3:

Newer, Faster, Better

We've upgraded the entire stack to take advantage of the latest features and releases across the entire toolchain. This means that out of the box, SAFE 3 now targets F# 5, .NET 5, Giraffe 5, Saturn 0.15 and Fable 3. All of these bring lots of goodies themselves - and SAFE Stack 3 gives you them all pre-configured and ready to go - but here are some of the main highlights and benefits you'll see from these new libraries:

  • Higher performance
  • Faster build times
  • New language features
  • Simplified toolchain

Also, we've made the decision to incorporate the Feliz library set into SAFE 3. Whilst we are aware of the costs of changes to a DSL in any platform, we feel that there's more momentum around the Feliz style, as well as a growing number of libraries and integration capabilities that it provides. And, since Feliz integrates with Fable.React, there's nothing to stop you creating apps that mix and match any style of DSL as you see fit.

Simpler and standardised experience

Probably one of the themes of SAFE 3 is "faster and more lightweight" than SAFE 2 (which was itself a simplification of SAFE 1). This can be seen not just in terms of execution time but in terms of the toolchain.

For example, we now no longer rely on the FAKE CLI runner to launch your SAFE applications; instead, the build process is itself now a console application that is part of the SAFE template. This presents several benefits such as simpler debuggability for your build tooling, but also means that now you can start your SAFE apps with a simple call as following:

dotnet new SAFE
dotnet run // no more dotnet fake build -t run !

Not only is this less to type, but it conforms with the standard ways that .NET applications are started nowadays.

Furthermore, Fable 3 is now a .NET Tool and no longer relies on WebPack. This not only means that it's possible to get your Fable apps working with alternative JS build tools / bundlers such as Parcel, but you can also now take any F# code and emit JS simply by calling the dotnet fable command. This opens up the door for possibilities such as emitting JS for non-UI services such as e.g. Cosmos DB Stored Procedures or Azure Stream Analytics UDFs.

Fresh Documentation

We've also updated all documentation on the SAFE docs website to be SAFE 3 ready (of course, if you see any omissions, please let us know!) and have also added a number of new recipies as well as a list of SAFE components (which we may incorporate into Fable's own component list in the future). We're also committed to creating several more fully-featured end-to-end demonstration apps, as we see this as a common ask.

Try out SAFE 3

Want to give SAFE Stack a go? Try this simple walkthrough and you'll be up and running in no time!

We hope you enjoy working with SAFE 3 - we're really happy with the state the stack is in, and are looking forward to continuing to improving it over time.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK