ImporterResults

Swift
public struct ImporterResults: Sendable

The results of loading a stylesheet through an importer.


Topics

Initializers

init(String, syntax: Syntax, sourceMapURL: URL?)

Initialize a new ImporterResults.

Declaration
Swift
public init(
    _ contents: String, syntax: Syntax = .scss, sourceMapURL: URL? = nil)
Parameters
contents

The stylesheet text.

syntax

The syntax of contents, default .scss.

sourceMapURL

Optionally, an absolute, browser-accessible URL for the stylesheet for reference from any source map that the compiler has been asked to generate. Ideally a file: URL, otherwise https:. If nil then the compiler uses an inline data: URL in the source map.

Properties

var contents: String

The contents of the stylesheet.

Declaration
Swift
public let contents: String

var syntax: Syntax

The syntax of the stylesheet.

Declaration
Swift
public let syntax: Syntax

var sourceMapURL: URL?

URL used to reference the stylesheet from a source map.

Declaration
Swift
public let sourceMapURL: URL?