@jungvonmatt/sb-migrate
Version:
CLI tool for managing Storyblok schema and content migrations
17 lines (16 loc) • 819 B
TypeScript
import { RunMigrationOptions } from "../../utils/migration";
/**
* Handles the deletion of a component based on the provided migration schema.
* This function performs the following operations:
* 1. Checks if the component exists
* 2. Deletes the component from the API
*
* @param {Object} migration - The migration object containing the component name
* @param {string | number} migration.name - The name or ID of the component to delete
* @param {RunMigrationOptions} options - Configuration options for the migration
* @param {boolean} [options.isDryrun] - Whether to perform a dry run without making actual changes
* @throws {Error} If the component deletion fails
*/
export declare const handleDeleteComponent: (migration: {
name: string | number;
}, options: RunMigrationOptions) => Promise<void>;