Skip to content

SPARQL Studio API / SparqlStudio / Config

Interface: Config<EndpointObject> ​

Defined in: sparql-studio/src/index.ts:29

Type Parameters ​

EndpointObject ​

EndpointObject extends CatalogueItem = CatalogueItem

Properties ​

autofocus ​

autofocus: boolean

Defined in: sparql-studio/src/index.ts:33

Autofocus yasqe on load or tab switch


endpointInfo ​

endpointInfo: ((tab?) => Element) | undefined

Defined in: sparql-studio/src/index.ts:34


copyEndpointOnNewTab ​

copyEndpointOnNewTab: boolean

Defined in: sparql-studio/src/index.ts:35


tabName ​

tabName: string

Defined in: sparql-studio/src/index.ts:36


corsProxy ​

corsProxy: string | undefined

Defined in: sparql-studio/src/index.ts:37


endpointCatalogueOptions ​

endpointCatalogueOptions: EndpointSelectConfig<EndpointObject>

Defined in: sparql-studio/src/index.ts:38


populateFromUrl ​

populateFromUrl: boolean | ((configFromUrl) => PersistedJson)

Defined in: sparql-studio/src/index.ts:40


autoAddOnInit ​

autoAddOnInit: boolean

Defined in: sparql-studio/src/index.ts:41


persistenceId ​

persistenceId: string | ((sparqlStudio) => string) | null

Defined in: sparql-studio/src/index.ts:42


persistenceLabelConfig ​

persistenceLabelConfig: string

Defined in: sparql-studio/src/index.ts:43


persistenceLabelResponse ​

persistenceLabelResponse: string

Defined in: sparql-studio/src/index.ts:44


persistencyExpire ​

persistencyExpire: number

Defined in: sparql-studio/src/index.ts:45


editor ​

editor: SparqlEditorFactory

Defined in: sparql-studio/src/index.ts:53

The editor factory. SparqlStudio is editor-independent: the consumer imports an editor (e.g. @rdfjs/sparql-editor-monaco for Monaco or @rdfjs/sparql-editor-codemirror for CodeMirror 6) and supplies a factory that builds it into parent, given the per-tab config SparqlStudio injects. Wire any editor-specific options (theme, language server, ...) inside the factory: editor: (parent, conf) => new SparqlEditor(parent, { ...conf, lsp: { client } })


results ​

results: Config

Defined in: sparql-studio/src/index.ts:54


requestConfig ​

requestConfig: YasguiRequestConfig

Defined in: sparql-studio/src/index.ts:55


contextMenuContainer ​

contextMenuContainer: HTMLElement | undefined

Defined in: sparql-studio/src/index.ts:56


nonSslDomain? ​

optional nonSslDomain?: string

Defined in: sparql-studio/src/index.ts:57


onEndpointChange? ​

optional onEndpointChange?: (sparqlStudio, endpoint) => void

Defined in: sparql-studio/src/index.ts:64

Called whenever the active SPARQL endpoint changes (on load, tab switch, or endpoint edit), with this SparqlStudio instance and the new endpoint. Defined once here, it applies to every tab. Typical use: configure the language server for that endpoint, e.g. onEndpointChange: (sparqlStudio, endpoint) => myConfigureBackend(sparqlStudio.editor?.getLanguageClient(), endpoint)

Parameters ​

sparqlStudio ​

SparqlStudio

endpoint ​

string

Returns ​

void