@alethio/cms-plugin-api
Advanced tools
Comparing version 1.0.0-beta.7 to 1.0.0-beta.8
@@ -0,1 +1,5 @@ | ||
# v1.0.0-beta.8 | ||
- Add definitions for data source dependencies (@alethio/cms@1.0.0-beta.12+) | ||
# v1.0.0-beta.7 | ||
@@ -2,0 +6,0 @@ |
@@ -0,3 +1,21 @@ | ||
import { IDataAdapterRefConfig } from "./IDataAdapterConfig"; | ||
export interface IDataSource { | ||
init(): Promise<void>; | ||
/** | ||
* Simple adapter dependencies when we depend on data from other plugins | ||
* | ||
* Only simple adapters are supported, meaning they must | ||
* - not depend on a data source being already initialized | ||
* - have a root contextType ({}), | ||
* - have no nested dependencies | ||
*/ | ||
dependencies?: IDataAdapterRefConfig[]; | ||
/** | ||
* Initializes the data source, performing any async operations needed to make the data source functional | ||
* | ||
* [cms v1.0.0-beta.12+]: If a dependencies array was specified, data loaded from each depending adapter is also passed to this method | ||
* | ||
* @param depData A map of adapter URIs to data returned by respective adapter. Adapter alias is also supported as key | ||
*/ | ||
init(depData: Map<string, unknown>): Promise<void>; | ||
} |
{ | ||
"name": "@alethio/cms-plugin-api", | ||
"version": "1.0.0-beta.7", | ||
"version": "1.0.0-beta.8", | ||
"types": "index", | ||
@@ -5,0 +5,0 @@ "description": "TypeScript definitions for Alethio CMS plugin API", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15847
287