DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports Events Over 2 million developers have joined DZone. Join Today! Thanks for visiting DZone today,
Edit Profile Manage Email Subscriptions Moderation Admin Console How to Post to DZone Article Submission Guidelines
View Profile
Sign Out
Refcards
Trend Reports
Events
Zones
Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
  1. DZone
  2. Software Design and Architecture
  3. Integration
  4. Getting Started With F#

Getting Started With F#

This post is a list of resources for learning F# and overview of my mini-project: Stock Estimator. Read on for the full list and more details.

Jacob Jedryszek user avatar by
Jacob Jedryszek
·
Apr. 19, 16 · Tutorial
Like (4)
Save
Tweet
Share
4.80K Views

Join the DZone community and get the full member experience.

Join For Free

I couldn’t resist anymore, and I finally tried F#. For the first two days, it was painful. Some elements of F# syntax are weird. However after getting used to that, F# became a joy, and instead of a week (as I planned) I spent almost two months with F#.

Getting Started

  • F# Jumpstart (Pluralsight) 1h 25m – brief introduction to F#, good for a sneak peak
  • Introduction to F# by Don Syme (part1, part2, part3)
  • F# for C# Developers by Phillip Trelford
  • Understanding the World with F# by Tomas Petricek
  • Try F# – interactive tutorial for learning F# (works only in IE because of Silverlight)
  • Functional Koans – F# – collection of F# exercises inspired by Ruby koans that requires you to fix failing unit tests one by one (fun and informative!)

Deep Dive

  • F# for beginners by Sacha Barber (Microsoft MVP) – extensive overview of almost all elements of F# language (good as reference)
  • Accessing Data with F# Type Providers (Pluralsight) by Tomas Petricek (2h 14m)
  • F# Functional Data Structures (Pluralsight) (3h 44m) – deep dive into F# Data Structures
  • Type-Driven Development with F# (Pluralsight) by Mark Seemann (3h 56m)
  • F# for fun and profit – solid source of knowledge to learn more about F# (when you know the basics)
  • fsharp.org – encyclopedia of resources for all topics related to F#
  • F# Advent Calendar 2014 and 2015 – set of articles about different topics related to F#
  • Domain modelling with the F# type system by Scott Wlaschin
  • Railway Oriented Programming — error handling in functional languages by Scott Wlaschin
  • Domain-Driven Design, Event Sourcing and CQRS with F# and EventStore by Lev Gorodinski

There is also a book written by Jon Skeet and Tomas Petricek: Real World Functional Programming: With Examples in F# and C#.

Testing

  • Unit Testing with F# (Pluralsight) by Mark Seemann (1h 32m)
  • Introduction to Property-based Testing with F# (Pluralsight) by Mark Seemann (1h 34m)
  • Test-Driven Development with F# (Pluralsight) by Mark Seemann (2h 17m)

Web Development

The most popular F# Web Framework is Suave. There is the SuaveMusicStore tutorial (code), which is inspired by ASP.NET MVC Music Store tutorial. If you want to build Web APIs with F#, check Building REST Api in Fsharp Using Suave.

It is also worth to check End-to-end Functional Web Development by Tomas Petricek where he showcases building a web app with Suave.

For more, check Web Programming with F# Guide.

Stock Estimator

I created an F#-based app for predicting future stock prices (a $1,000,000 idea!). The back-end is written in F# and communicates with a stock data API (Yahoo Finance) through an F# type provider. There is also Suave Web API (microservice), and ASP.NET Core web app that communicates with it. The front-end is powered by Aurelia Framework and D3 library. In other words, I built the F# microservice, consumed it from a non-F# app, and have reusable logic in a separate project. All communication with microservices happens through the client (with Aurelia Framework). So, there is no usage of F# from C#, but… I also created a simple Console app (with C#) that uses mentioned F# logic. There is also a Windows Forms app for displaying estimates, written in F#, that also has use reusable logic.

Entire source code is available on GitHub. Check it out!

Summary

Programming in F# is pure joy! It’s a great language for working with data. Moreover, F# fits perfectly into today’s world of microservices. You don’t have to rewrite your existing app or create an entire app with F#. You can just create one microservice with F# and see how it works for you!

app unit test Web API

Published at DZone with permission of Jacob Jedryszek, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • How to Submit a Post to DZone
  • The Quest for REST
  • A Brief Overview of the Spring Cloud Framework
  • How To Check Docker Images for Vulnerabilities

Comments

Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends: