Skip to content

buildThemeFromScheme

The purpose of this function is to build a theme object, ready to be used in a theme file, from a scheme configuration.

buildThemeFromScheme(config: BuildThemeFromSchemeOptions): object

Parameters

NameTypeDescription
configBuildThemeFromSchemeOptionsThe configuration object for the theme.

BuildThemeFromSchemeOptions

interface BuildThemeFromSchemeOptions {
name: string
scheme: FullTheme
isBordered?: boolean
}

Returns

An object representing the theme. (The object is very large, so it is not practical to show it here.)

Example

import { buildThemeFromScheme, createSchemeFromColors, exampleTheme } from 'vs-theme-builder';
const name = 'My Theme';
const scheme = createSchemeFromColors({ colors: exampleTheme });
const theme = buildThemeFromScheme({
scheme,
name,
isBordered: false
})