Skip to content

pantoken-root / platforms/canvas-theme-editor/src / CdnProvider

Interfaccia: CdnProvider ​

Alpha

Una CDN che può servire file di pacchetti npm. I provider non codificano mai un nome di pacchetto — conoscono solo come costruire un URL da un CdnFile.

Proprietà ​

id ​

id: string

Alpha

Identificatore stabile, es. "jsdelivr".


label ​

label: string

Alpha

Nome leggibile, es. "jsDelivr".


supportsCombine ​

supportsCombine: boolean

Alpha

Se CdnProvider.buildCombineUrl è implementato.

Metodi ​

buildUrl() ​

buildUrl(file, options?): string

Alpha

Costruisce l'URL per un singolo file.

Parametri ​

file ​

CdnFile

options? ​

CdnBuildOptions

Restituisce ​

string


buildCombineUrl()? ​

optional buildCombineUrl(files, options?): string

Alpha

Costruisce un URL che serve più file concatenati insieme. Richiesto se e solo se supportsCombine.

Parametri ​

files ​

CdnFile[]

options? ​

CdnBuildOptions

Restituisce ​

string