mirror of
https://github.com/iconify/iconify.git
synced 2025-01-12 01:45:41 +00:00
Require resources property in API config
This commit is contained in:
parent
027a317e4e
commit
d1b7d76d97
@ -11,7 +11,8 @@ export interface IconifyAPIConfig extends RedundancyConfig {
|
||||
maxURL: number;
|
||||
}
|
||||
|
||||
export type PartialIconifyAPIConfig = Partial<IconifyAPIConfig>;
|
||||
export type PartialIconifyAPIConfig = Partial<IconifyAPIConfig> &
|
||||
Pick<IconifyAPIConfig, 'resources'>;
|
||||
|
||||
/**
|
||||
* Create full API configuration from partial data
|
||||
|
@ -5,7 +5,7 @@ import type {
|
||||
IconifyIconLoaderAbort,
|
||||
IconifyIconLoaderCallback,
|
||||
} from '../interfaces/loader';
|
||||
import type { GetAPIConfig, IconifyAPIConfig } from './config';
|
||||
import type { GetAPIConfig, PartialIconifyAPIConfig } from './config';
|
||||
import { getAPIConfig, setAPIConfig } from './config';
|
||||
import type { IconifyAPIModule } from './modules';
|
||||
import { setAPIModule } from './modules';
|
||||
@ -27,7 +27,7 @@ export interface IconifyAPIFunctions {
|
||||
*/
|
||||
addAPIProvider: (
|
||||
provider: string,
|
||||
customConfig: Partial<IconifyAPIConfig>
|
||||
customConfig: PartialIconifyAPIConfig
|
||||
) => boolean;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user