JetBrains Rider 2017.2 Help

Coding Assistance in F#

This topic describes JetBrains Rider's coding assistance features available in F#.

You can find the detailed information on these features in the corresponding topics of the Coding Assistance section.

Syntax highlighting

F# syntax highlighting uses the default font and color scheme that is applied to all languages and currently cannot be customized specifically for F#.

Default syntax highlighting:

FSharp syntax highlighting

To configure default color and font settings:

  1. Press Ctrl+Alt+S, or alternatively choose File | Settings on Windows and Linux or Rider | Preferences on macOS, then choose Editor | Color Scheme on the left.
  2. Change the settings under the General and Language Defaults nodes.

rdr settings language defaults

Code completion

Code Completion features help you write code faster by providing a set of items to complete based on surrounding context. For more information, see Code Completion (IntelliSense).

Currently, only Basic code completion is supported in F#. It suggests namespaces, types, methods, fields, properties, etc. as you type.

FSharp basic code completion

You can see the entire list of suggestions by placing the caret at the position where you're going to type your code (or on an existing member) and press Ctrl+Space.

FSharp basic code completion ctrl space

Code formatting

JetBrains Rider can reformat existing code in a selected F# file, fixing the following spacing violations:

  • space after comma
  • space after semicolon
  • space around delimiter
  • space before argument
  • space before colon
  • inconsistent indents

Open the file you want to reformat, then go to Code | Reformat Code or just press Ctrl+Alt+Enter.

Here is an example of a code fragment reformatted with JetBrains Rider.


FSharp reformatting before


FSharp reformatting after
Last modified: 27 December 2017