type CDN = 'jsdelivr' | 'unpkg' | 'cdnjs' | 'staticfile'

interface CommonConfig {
  /**
   * cdn services
   */
  cdn?: CDN
  /**
   * custom cdn url
   */
  src?: string
}

interface ActiveConfig {
  /**
   * define is active override debug
   */
  override?: boolean
  /**
   * use url or storage
   */
  mode: 'url' | 'storage'
  /**
   * parameter name
   */
  param: string
}

interface SharedConfig {
  /**
   * debug or not
   */
  debug?: boolean
  /**
   * active debugger
   */
  active?: ActiveConfig
  /**
   * use node_modules
   */
  local?: boolean
  /**
   * if local is true, use this to specify the path
   */
  entry?: string | string[]
}

export type { CommonConfig as C, SharedConfig as S };
