options

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 14, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultThemes = []Theme{
	{Name: "Solarized"},
	{Name: "Tokyo Night"},
	{Name: "Catppuccin Mocha"},
}

Functions

This section is empty.

Types

type Options

type Options struct {
	OpenAPI   string `yaml:"openapi"`
	Changelog string `yaml:"changelog"`
	Docs      string `yaml:"docs"`
	RootDoc   string `yaml:"rootDoc"`
	Out       string `yaml:"out"`
	// List of languages for which to generate code
	Codegen []string `yaml:"codegen"`
	// List of available color themes.
	// See the [example options] for usage.
	//
	// [example options]: https://gitlab.com/manabug/webscope/-/blob/main/examples/webscope.yaml
	Themes []Theme `yaml:"themes"`
}

func Load

func Load(path string) (*Options, error)

func (*Options) GetThemes added in v0.6.0

func (o *Options) GetThemes() []Theme

GetThemes returns o.Themes if it has been configured, otherwise, returns DefaultThemes

type Theme added in v0.6.0

type Theme struct {
	// Name of the theme in the theme selector, as well as the theme name in CSS.
	Name string `yaml:"name"`
	// Colors of the theme.
	// For available options, see the [example options].
	//
	// [example options]: https://gitlab.com/manabug/webscope/-/blob/main/examples/webscope.yaml
	Colors map[string]string `yaml:"colors"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL