loadPlugins() — astro Function Reference
Architecture documentation for the loadPlugins() function in load-plugins.ts from the astro codebase.
Entity Profile
Dependency Diagram
graph TD 1bd356d0_f7e9_b2c5_1d9e_f1a15e556f72["loadPlugins()"] 005bacb3_f924_d887_25a0_84c0b6efe1be["load-plugins.ts"] 1bd356d0_f7e9_b2c5_1d9e_f1a15e556f72 -->|defined in| 005bacb3_f924_d887_25a0_84c0b6efe1be bd2a8d12_3d39_7568_0bce_8046e9507c49["importPlugin()"] 1bd356d0_f7e9_b2c5_1d9e_f1a15e556f72 -->|calls| bd2a8d12_3d39_7568_0bce_8046e9507c49 style 1bd356d0_f7e9_b2c5_1d9e_f1a15e556f72 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/markdown/remark/src/load-plugins.ts lines 12–34
export function loadPlugins(
items: (
| string
| [string, any]
| unified.Plugin<any[], any>
| [unified.Plugin<any[], any>, any]
)[],
): Promise<[unified.Plugin, any?]>[] {
return items.map((p) => {
return new Promise((resolve, reject) => {
if (Array.isArray(p)) {
const [plugin, opts] = p;
return importPlugin(plugin)
.then((m) => resolve([m, opts]))
.catch((e) => reject(e));
}
return importPlugin(p)
.then((m) => resolve([m]))
.catch((e) => reject(e));
});
});
}
Domain
Subdomains
Defined In
Calls
Source
Frequently Asked Questions
What does loadPlugins() do?
loadPlugins() is a function in the astro codebase, defined in packages/markdown/remark/src/load-plugins.ts.
Where is loadPlugins() defined?
loadPlugins() is defined in packages/markdown/remark/src/load-plugins.ts at line 12.
What does loadPlugins() call?
loadPlugins() calls 1 function(s): importPlugin.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free