Documentation
¶
Index ¶
- Constants
- func New(apiFilesDir string, opts ...Option) (string, error)
- func NewV2(opts ...Option) (string, error)
- func WithAuthentication(authentication string) func(*Options)
- func WithAuthenticationOpts(opts ...AuthOption) func(*Options)
- func WithBaseFileName(baseFileName string) func(*Options)
- func WithBaseServerURL(baseServerURL string) func(*Options)
- func WithCDN(cdn string) func(*Options)
- func WithCustomBodyJS(js string) func(*Options)
- func WithCustomCSS(css string) func(*Options)
- func WithCustomHeadJS(js string) func(*Options)
- func WithDarkMode() func(*Options)
- func WithDefaultFonts() func(*Options)
- func WithDefaultHTTPClient(target, client string) func(*Options)
- func WithEditable() func(*Options)
- func WithForceDarkMode() func(*Options)
- func WithHiddenClients(hiddenClients ...string) func(*Options)
- func WithHideAllClients() func(*Options)
- func WithHideDarkModeToggle() func(*Options)
- func WithHideDownloadButton() func(*Options)
- func WithHideModels() func(*Options)
- func WithHideSearch(hide bool) func(*Options)
- func WithKeyValue(key string, value any) func(MetaData)
- func WithLayout(layout Layout) func(*Options)
- func WithMetaDataOpts(metadataOpts ...MetaOption) func(*Options)
- func WithMultipleSources(sources ...DocumentSource) func(*Options)
- func WithOperationTitleSource(source OperationTitleSource) func(*Options)
- func WithOperationsSorter(sorter SorterOption) func(*Options)
- func WithOrderSchemaPropertiesBy(order SchemaPropertiesOrder) func(*Options)
- func WithOverrideCSS(overrideCSS string) func(*Options)
- func WithPathRouting(pathRouting string) func(*Options)
- func WithPersistAuth(persist bool) func(*Options)
- func WithProxy(proxy string) func(*Options)
- func WithRenderMode(mode RenderMode) func(*Options)
- func WithSearchHotKey(searchHotKey string) func(*Options)
- func WithServers(servers ...ServerOverride) func(*Options)
- func WithShowOperationID(show bool) func(*Options)
- func WithShowToolbar(visibility ShowToolbarOption) func(*Options)
- func WithSidebarVisibility(visible bool) func(*Options)
- func WithSpecBytes(specBytes []byte) func(*Options)
- func WithSpecDir(specDir string) func(*Options)
- func WithSpecModifier(handler SpecModifier) func(*Options)
- func WithSpecURL(specURL string) func(*Options)
- func WithTagsSorter(sorter SorterOption) func(*Options)
- func WithTheme(theme Theme) func(*Options)
- func WithTitle(title string) func(MetaData)
- type APIKeyConfig
- type APIKeyLocation
- type APIKeyOption
- type AuthOption
- func WithAPIKey(token string, opts ...APIKeyOption) AuthOption
- func WithAPIKeyCookie(name, token string) AuthOption
- func WithAPIKeyHeader(name, token string) AuthOption
- func WithAPIKeyQuery(name, token string) AuthOption
- func WithCustomSecurity() AuthOption
- func WithHTTPBasicAuth(username, password string) AuthOption
- func WithHTTPBearerToken(token string) AuthOption
- func WithOAuth2AuthorizationCode(authorizationURL, tokenURL string, opts ...OAuth2Option) AuthOption
- func WithOAuth2ClientCredentials(tokenURL string, opts ...OAuth2Option) AuthOption
- func WithOAuth2Implicit(authorizationURL string, opts ...OAuth2Option) AuthOption
- func WithOAuth2Password(tokenURL string, opts ...OAuth2Option) AuthOption
- func WithPreferredSecurityScheme(schemes ...any) AuthOption
- func WithSecurityScheme(name string, config SecuritySchemeConfig) AuthOption
- type AuthenticationOption
- type DocumentSource
- type HTTPClientConfig
- type Layout
- type MetaData
- type MetaOption
- type OAuth2Config
- type OAuth2CredentialsLocation
- type OAuth2FlowType
- type OAuth2Option
- func WithOAuth2AdditionalAuthParams(params map[string]string) OAuth2Option
- func WithOAuth2AdditionalTokenParams(params map[string]string) OAuth2Option
- func WithOAuth2ClientID(clientID string) OAuth2Option
- func WithOAuth2ClientSecret(clientSecret string) OAuth2Option
- func WithOAuth2CredentialsLocation(location OAuth2CredentialsLocation) OAuth2Option
- func WithOAuth2CustomToken(tokenName string) OAuth2Option
- func WithOAuth2PKCE(mode OAuth2PKCEMode) OAuth2Option
- func WithOAuth2RedirectURI(redirectURI string) OAuth2Option
- func WithOAuth2Scopes(scopes ...string) OAuth2Option
- type OAuth2PKCEMode
- type OperationTitleSource
- type Option
- type Options
- type RenderMode
- type SchemaPropertiesOrder
- type SecuritySchemeConfig
- type Serverdeprecated
- type ServerOverride
- type ShowToolbarOption
- type SorterOption
- type SpecModifier
- type Theme
Constants ¶
const ( ClientAsyncHTTP = "asynchttp" ClientAxios = "axios" ClientCljHTTP = "clj_http" ClientCoHTTP = "cohttp" ClientCurl = "curl" ClientFetch = "fetch" ClientGuzzle = "guzzle" ClientHTTP1 = "http1.1" ClientHTTPClient = "httpclient" ClientHTTP2 = "http2" ClientHttpie = "httpie" ClientHttr = "httr" ClientJquery = "jquery" ClientLibCurl = "libcurl" ClientNative = "native" ClientNetHTTP = "nethttp" ClientNsurlSession = "nsurlsession" ClientOkHTTP = "okhttp" ClientOkhttp = "okhttp" ClientPython3 = "python3" ClientRequest = "request" ClientRequests = "requests" ClientRestMethod = "restmethod" ClientRestSharp = "restsharp" ClientUndici = "undici" ClientUnirest = "unirest" ClientWebRequest = "webrequest" ClientWget = "wget" ClientXhr = "xhr" ClientHTTP = "http" ClientOfetch = "ofetch" ClientHTTPXSync = "httpxsync" ClientHTTPXAsync = "httpxasync" ClientReqWest = "reqwest" )
List of known clients
const DefaultCDN = "https://cdn.jsdelivr.net/npm/@scalar/api-reference"
DefaultCDN default CDN for api-reference
Variables ¶
This section is empty.
Functions ¶
func WithAuthentication ¶
WithAuthentication sets the authentication method for the Scalar UI
func WithAuthenticationOpts ¶ added in v0.12.0
func WithAuthenticationOpts(opts ...AuthOption) func(*Options)
WithAuthenticationOpts sets the authentication method for the Scalar UI
func WithBaseFileName ¶
WithBaseFileName sets the base file name for the Scalar UI
func WithBaseServerURL ¶
WithBaseServerURL sets the base server URL for the Scalar UI
func WithCustomBodyJS ¶ added in v0.13.0
WithCustomBodyJS injects custom JavaScript in the <body> after Scalar initialization Note: User is responsible for XSS prevention in custom JS
func WithCustomCSS ¶ added in v0.13.0
WithCustomCSS sets custom CSS in the configuration object (different from WithOverrideCSS which injects CSS in <style> tag)
func WithCustomHeadJS ¶ added in v0.13.0
WithCustomHeadJS injects custom JavaScript in the <head> before the Scalar CDN script Note: User is responsible for XSS prevention in custom JS
func WithDefaultFonts ¶
func WithDefaultFonts() func(*Options)
WithDefaultFonts sets the default fonts usage for the Scalar UI
func WithDefaultHTTPClient ¶ added in v0.13.0
WithDefaultHTTPClient sets the default HTTP client for code examples
func WithEditable ¶
func WithEditable() func(*Options)
WithEditable sets the editable state for the Scalar UI
func WithForceDarkMode ¶ added in v0.5.0
func WithForceDarkMode() func(*Options)
WithForceDarkMode makes it always this state no matter what
func WithHiddenClients ¶
WithHiddenClients hide the set clients
func WithHideAllClients ¶ added in v0.6.0
func WithHideAllClients() func(*Options)
WithHideAllClients sets the hidden clients for the Scalar UI
func WithHideDarkModeToggle ¶ added in v0.5.0
func WithHideDarkModeToggle() func(*Options)
WithHideDarkModeToggle hides the dark mode toggle button
func WithHideDownloadButton ¶
func WithHideDownloadButton() func(*Options)
WithHideDownloadButton hide to download OpenAPI spec button
func WithHideModels ¶
func WithHideModels() func(*Options)
WithHideModels sets the models visibility for the Scalar UI
func WithHideSearch ¶ added in v0.13.0
WithHideSearch hides or shows the search functionality in the Scalar UI
func WithKeyValue ¶ added in v0.5.0
WithKeyValue add metadata with key and value
func WithLayout ¶
WithLayout sets the layout for the Scalar UI
func WithMetaDataOpts ¶ added in v0.5.0
func WithMetaDataOpts(metadataOpts ...MetaOption) func(*Options)
WithMetaDataOpts add metadata
func WithMultipleSources ¶ added in v0.13.0
func WithMultipleSources(sources ...DocumentSource) func(*Options)
WithMultipleSources configures multiple OpenAPI document sources for multi-version API documentation
func WithOperationTitleSource ¶ added in v0.13.0
func WithOperationTitleSource(source OperationTitleSource) func(*Options)
WithOperationTitleSource sets where to get operation titles from (summary or path)
func WithOperationsSorter ¶ added in v0.13.0
func WithOperationsSorter(sorter SorterOption) func(*Options)
WithOperationsSorter sets how operations are sorted within tags
func WithOrderSchemaPropertiesBy ¶ added in v0.13.0
func WithOrderSchemaPropertiesBy(order SchemaPropertiesOrder) func(*Options)
WithOrderSchemaPropertiesBy sets how schema properties are ordered
func WithOverrideCSS ¶
WithOverrideCSS sets the override CSS for the Scalar UI
func WithPathRouting ¶
WithPathRouting sets the path routing for the Scalar UI
func WithPersistAuth ¶ added in v0.13.0
WithPersistAuth enables or disables persisting authentication credentials in localStorage
func WithRenderMode ¶ added in v0.13.0
func WithRenderMode(mode RenderMode) func(*Options)
WithRenderMode sets the rendering mode for the Scalar UI
func WithSearchHotKey ¶
WithSearchHotKey sets the search hot key for the Scalar UI
func WithServers ¶ added in v0.5.0
func WithServers(servers ...ServerOverride) func(*Options)
WithServers servers to override the openapi spec servers
func WithShowOperationID ¶ added in v0.13.0
WithShowOperationID shows or hides operation IDs in the Scalar UI
func WithShowToolbar ¶ added in v0.13.0
func WithShowToolbar(visibility ShowToolbarOption) func(*Options)
WithShowToolbar controls the visibility of the developer tools toolbar Accepts: ShowToolbarAlways, ShowToolbarLocalhost, or ShowToolbarNever Default in this library: ShowToolbarNever (differs from Scalar's default of localhost)
func WithSidebarVisibility ¶
WithSidebarVisibility sets the sidebar visibility for the Scalar UI
func WithSpecBytes ¶ added in v0.12.1
WithSpecBytes loads the spec from the provided bytes in either YAML or JSON format
func WithSpecDir ¶ added in v0.6.0
WithSpecDir read spec from directory
func WithSpecModifier ¶ added in v0.0.6
func WithSpecModifier(handler SpecModifier) func(*Options)
WithSpecModifier allows to modify the spec before rendering
func WithSpecURL ¶ added in v0.6.0
WithSpecURL set the spec URL in the doc
func WithTagsSorter ¶ added in v0.13.0
func WithTagsSorter(sorter SorterOption) func(*Options)
WithTagsSorter sets how tags are sorted in the sidebar
Types ¶
type APIKeyConfig ¶ added in v0.13.0
type APIKeyConfig struct {
Token string `json:"token"`
Name string `json:"name,omitempty"`
In APIKeyLocation `json:"in,omitempty"`
}
APIKeyConfig holds API key configuration
type APIKeyLocation ¶ added in v0.13.0
type APIKeyLocation string
APIKeyLocation specifies where the API key is transmitted
const ( APIKeyLocationHeader APIKeyLocation = "header" APIKeyLocationQuery APIKeyLocation = "query" APIKeyLocationCookie APIKeyLocation = "cookie" )
type APIKeyOption ¶ added in v0.13.0
type APIKeyOption func(*APIKeyConfig)
APIKeyOption configures API key authentication
func WithAPIKeyLocation ¶ added in v0.13.0
func WithAPIKeyLocation(location APIKeyLocation) APIKeyOption
WithAPIKeyLocation sets where the API key is sent
func WithAPIKeyName ¶ added in v0.13.0
func WithAPIKeyName(name string) APIKeyOption
WithAPIKeyName sets the parameter name for the API key
type AuthOption ¶ added in v0.12.0
type AuthOption func(AuthenticationOption)
func WithAPIKey ¶ added in v0.12.0
func WithAPIKey(token string, opts ...APIKeyOption) AuthOption
WithAPIKey configures API key authentication with optional configuration
func WithAPIKeyCookie ¶ added in v0.13.0
func WithAPIKeyCookie(name, token string) AuthOption
WithAPIKeyCookie is a shorthand for cookie-based API keys
func WithAPIKeyHeader ¶ added in v0.13.0
func WithAPIKeyHeader(name, token string) AuthOption
WithAPIKeyHeader is a shorthand for header-based API keys
func WithAPIKeyQuery ¶ added in v0.13.0
func WithAPIKeyQuery(name, token string) AuthOption
WithAPIKeyQuery is a shorthand for query parameter-based API keys
func WithCustomSecurity ¶ added in v0.12.0
func WithCustomSecurity() AuthOption
WithCustomSecurity sets the custom security toggle to true
func WithHTTPBasicAuth ¶ added in v0.12.0
func WithHTTPBasicAuth(username, password string) AuthOption
WithHTTPBasicAuth sets the HTTP Basic Auth options
func WithHTTPBearerToken ¶ added in v0.12.0
func WithHTTPBearerToken(token string) AuthOption
WithHTTPBearerToken sets the HTTP Bearer Token options
func WithOAuth2AuthorizationCode ¶ added in v0.13.0
func WithOAuth2AuthorizationCode(authorizationURL, tokenURL string, opts ...OAuth2Option) AuthOption
WithOAuth2AuthorizationCode configures OAuth2 Authorization Code flow
func WithOAuth2ClientCredentials ¶ added in v0.13.0
func WithOAuth2ClientCredentials(tokenURL string, opts ...OAuth2Option) AuthOption
WithOAuth2ClientCredentials configures OAuth2 Client Credentials flow
func WithOAuth2Implicit ¶ added in v0.13.0
func WithOAuth2Implicit(authorizationURL string, opts ...OAuth2Option) AuthOption
WithOAuth2Implicit configures OAuth2 Implicit flow (deprecated but supported for compatibility)
func WithOAuth2Password ¶ added in v0.13.0
func WithOAuth2Password(tokenURL string, opts ...OAuth2Option) AuthOption
WithOAuth2Password configures OAuth2 Password flow (deprecated but supported for compatibility)
func WithPreferredSecurityScheme ¶ added in v0.12.0
func WithPreferredSecurityScheme(schemes ...any) AuthOption
WithPreferredSecurityScheme sets the preferred security scheme Acceptable values: 1. Single security scheme: "my_custom_security_scheme" 2. Multiple security schemes: "my_custom_security_scheme", "another_security_scheme" 3. Complex security schemes: ["my_custom_security_scheme", "another_security_scheme"], "yet-another_security_scheme"
func WithSecurityScheme ¶ added in v0.13.0
func WithSecurityScheme(name string, config SecuritySchemeConfig) AuthOption
WithSecurityScheme adds a named security scheme configuration
type AuthenticationOption ¶ added in v0.12.0
type DocumentSource ¶ added in v0.13.0
type DocumentSource struct {
Title string `json:"title,omitempty"` // Display title for this document
Slug string `json:"slug,omitempty"` // URL slug for routing
URL string `json:"url,omitempty"` // URL to fetch the OpenAPI document
Content string `json:"content,omitempty"` // Inline OpenAPI document content (mutually exclusive with URL)
Default bool `json:"default,omitempty"` // Whether this is the default document to display
}
DocumentSource represents a single OpenAPI document source for multi-document configurations
type HTTPClientConfig ¶ added in v0.13.0
type HTTPClientConfig struct {
TargetKey string `json:"targetKey"` // Target language/platform (e.g., "node", "php", "python")
ClientKey string `json:"clientKey"` // Specific client library (e.g., "undici", "guzzle", "requests")
}
HTTPClientConfig configures the default HTTP client to use in the Scalar UI
type MetaOption ¶ added in v0.5.0
type MetaOption func(MetaData)
type OAuth2Config ¶ added in v0.13.0
type OAuth2Config struct {
AuthorizationURL string `json:"authorizationUrl,omitempty"`
TokenURL string `json:"tokenUrl,omitempty"`
ClientID string `json:"x-scalar-client-id,omitempty"`
ClientSecret string `json:"clientSecret,omitempty"`
RedirectURI string `json:"x-scalar-redirect-uri,omitempty"`
UsePKCE OAuth2PKCEMode `json:"x-usePkce,omitempty"`
SelectedScopes []string `json:"selectedScopes,omitempty"`
SecurityQuery map[string]string `json:"x-scalar-security-query,omitempty"`
SecurityBody map[string]string `json:"x-scalar-security-body,omitempty"`
TokenName string `json:"x-tokenName,omitempty"`
CredentialsLocation OAuth2CredentialsLocation `json:"x-scalar-credentials-location,omitempty"`
}
OAuth2Config holds OAuth2 flow configuration
type OAuth2CredentialsLocation ¶ added in v0.13.0
type OAuth2CredentialsLocation string
OAuth2CredentialsLocation specifies where credentials are sent
const ( OAuth2CredentialsHeader OAuth2CredentialsLocation = "header" OAuth2CredentialsBody OAuth2CredentialsLocation = "body" )
type OAuth2FlowType ¶ added in v0.13.0
type OAuth2FlowType string
OAuth2FlowType represents different OAuth2 flow types
const ( OAuth2FlowAuthorizationCode OAuth2FlowType = "authorizationCode" OAuth2FlowClientCredentials OAuth2FlowType = "clientCredentials" OAuth2FlowImplicit OAuth2FlowType = "implicit" OAuth2FlowPassword OAuth2FlowType = "password" )
type OAuth2Option ¶ added in v0.13.0
type OAuth2Option func(*OAuth2Config)
OAuth2Option configures OAuth2 authentication
func WithOAuth2AdditionalAuthParams ¶ added in v0.13.0
func WithOAuth2AdditionalAuthParams(params map[string]string) OAuth2Option
WithOAuth2AdditionalAuthParams adds additional query parameters to the authorization endpoint
func WithOAuth2AdditionalTokenParams ¶ added in v0.13.0
func WithOAuth2AdditionalTokenParams(params map[string]string) OAuth2Option
WithOAuth2AdditionalTokenParams adds additional body parameters to the token endpoint
func WithOAuth2ClientID ¶ added in v0.13.0
func WithOAuth2ClientID(clientID string) OAuth2Option
WithOAuth2ClientID sets the OAuth2 client ID
func WithOAuth2ClientSecret ¶ added in v0.13.0
func WithOAuth2ClientSecret(clientSecret string) OAuth2Option
WithOAuth2ClientSecret sets the OAuth2 client secret
func WithOAuth2CredentialsLocation ¶ added in v0.13.0
func WithOAuth2CredentialsLocation(location OAuth2CredentialsLocation) OAuth2Option
WithOAuth2CredentialsLocation sets where client credentials are sent
func WithOAuth2CustomToken ¶ added in v0.13.0
func WithOAuth2CustomToken(tokenName string) OAuth2Option
WithOAuth2CustomToken sets a custom token field name
func WithOAuth2PKCE ¶ added in v0.13.0
func WithOAuth2PKCE(mode OAuth2PKCEMode) OAuth2Option
WithOAuth2PKCE enables PKCE with the specified mode
func WithOAuth2RedirectURI ¶ added in v0.13.0
func WithOAuth2RedirectURI(redirectURI string) OAuth2Option
WithOAuth2RedirectURI sets the OAuth2 redirect URI
func WithOAuth2Scopes ¶ added in v0.13.0
func WithOAuth2Scopes(scopes ...string) OAuth2Option
WithOAuth2Scopes sets the pre-selected OAuth2 scopes
type OAuth2PKCEMode ¶ added in v0.13.0
type OAuth2PKCEMode string
OAuth2PKCEMode represents PKCE configuration modes
const ( PKCES256 OAuth2PKCEMode = "S256" PKCEPlain OAuth2PKCEMode = "plain" PKCEDisabled OAuth2PKCEMode = "no" )
type OperationTitleSource ¶ added in v0.13.0
type OperationTitleSource string
OperationTitleSource defines where to get operation titles from
const ( // OperationTitleSourceSummary uses the summary field OperationTitleSourceSummary OperationTitleSource = "summary" // OperationTitleSourcePath uses the path OperationTitleSourcePath OperationTitleSource = "path" )
type Options ¶
type Options struct {
Configurations map[string]any
OverrideCSS string
BaseFileName string
CDN string
SpecModifier SpecModifier
SpecDirectory string
SpecURL string
SpecBytes []byte
RenderMode RenderMode
CustomHeadJS string // Custom JavaScript to inject in <head> before Scalar CDN script
CustomBodyJS string // Custom JavaScript to inject in <body> after Scalar initialization
}
func (*Options) BuildInitScript ¶ added in v0.13.0
BuildInitScript generates JavaScript initialization code for JavaScript API mode Returns: Scalar.createApiReference('#api-reference', {config});
func (*Options) GetSpecScript ¶ added in v0.6.0
GetSpecScript prepares and returns the spec script, routing to appropriate method based on RenderMode
type RenderMode ¶ added in v0.13.0
type RenderMode string
RenderMode defines how Scalar initializes in the HTML output
const ( // RenderModeDataAttribute uses data attributes on script tag (legacy, available for backward compatibility) RenderModeDataAttribute RenderMode = "data-attribute" // RenderModeJavaScriptAPI uses Scalar.createApiReference() JavaScript API (recommended, default) RenderModeJavaScriptAPI RenderMode = "javascript-api" )
type SchemaPropertiesOrder ¶ added in v0.13.0
type SchemaPropertiesOrder string
SchemaPropertiesOrder defines how to order schema properties
const ( // SchemaPropertiesOrderAlpha sorts properties alphabetically SchemaPropertiesOrderAlpha SchemaPropertiesOrder = "alpha" // SchemaPropertiesOrderPreserve preserves the order from the spec SchemaPropertiesOrderPreserve SchemaPropertiesOrder = "preserve" )
type SecuritySchemeConfig ¶ added in v0.13.0
SecuritySchemeConfig represents configuration for a single security scheme
func APIKeyScheme ¶ added in v0.13.0
func APIKeyScheme(name string, location APIKeyLocation, value string) SecuritySchemeConfig
APIKeyScheme creates an API key security scheme configuration
func BasicScheme ¶ added in v0.13.0
func BasicScheme(username, password string) SecuritySchemeConfig
BasicScheme creates a basic auth security scheme configuration
func BearerScheme ¶ added in v0.13.0
func BearerScheme(token string) SecuritySchemeConfig
BearerScheme creates a bearer token security scheme configuration
func OAuth2Scheme ¶ added in v0.13.0
func OAuth2Scheme(flow OAuth2FlowType, config OAuth2Config) SecuritySchemeConfig
OAuth2Scheme creates an OAuth2 security scheme configuration
type Server
deprecated
added in
v0.5.0
type Server = ServerOverride
Server is alias exists for backwards compatibility but will be removed in a future version. The name was changed to avoid collision with model.Server.
Deprecated: use ServerOverride instead.
type ServerOverride ¶ added in v0.13.0
ServerOverride represents server override configuration for UI display. This is a simplified version of model.Server, used to quickly override server URLs without needing the full OpenAPI server specification.
type ShowToolbarOption ¶ added in v0.13.0
type ShowToolbarOption string
ShowToolbarOption defines when to display the developer tools toolbar
const ( // ShowToolbarAlways displays the toolbar in all environments ShowToolbarAlways ShowToolbarOption = "always" // ShowToolbarLocalhost displays toolbar only on localhost or similar hosts (Scalar default) ShowToolbarLocalhost ShowToolbarOption = "localhost" // ShowToolbarNever never displays the toolbar ShowToolbarNever ShowToolbarOption = "never" )
type SorterOption ¶ added in v0.13.0
type SorterOption string
SorterOption defines sorting behavior for tags and operations
const ( // SorterAlpha sorts alphabetically SorterAlpha SorterOption = "alpha" // SorterMethod sorts by HTTP method (for operations only) SorterMethod SorterOption = "method" )
type SpecModifier ¶ added in v0.0.6
SpecModifier is a function that can be used to override the spec
type Theme ¶
type Theme string
Theme as a type based on string for theme identification
const ( ThemeDefault Theme = "default" ThemeAlternate Theme = "alternate" ThemeMoon Theme = "moon" ThemePurple Theme = "purple" ThemeSolarized Theme = "solarized" ThemeBluePlanet Theme = "bluePlanet" ThemeDeepSpace Theme = "deepSpace" ThemeSaturn Theme = "saturn" ThemeKepler Theme = "kepler" ThemeMars Theme = "mars" ThemeNone Theme = "none" ThemeNil Theme = "" )