Contents

SupportedLanguage

A directive that controls what programming languages an article is available in.

Declaration

@SupportedLanguage(_ language: SourceLanguage)

Parameters

  • language:

    A source language that this symbol is available in. (required)

    For supported values, see Supportedlanguage.

Overview

By default, an article is available in the languages the module that’s being documented is available in. Use this directive to override this behavior in a Metadata directive:

@Metadata {
    @SupportedLanguage(swift)
    @SupportedLanguage(objc)
}

This directive supports any language identifier, but only the following are currently supported by Swift-DocC Render:

Identifier

Language

swift

Swift

objc, objective-c

Objective-C

See Also

Customizing the Languages of an Article