UNPKG

@botonic/plugin-flow-builder

Version:

Use Flow Builder to show your contents

17 lines 729 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getFlowBuilderPlugin = void 0; const FLOW_BUILDER_PLUGIN_NAME = 'BotonicPluginFlowBuilder'; function getFlowBuilderPlugin(plugins) { const ERROR_MESSAGE = `You must include '@botonic/plugin-flow-builder' in your plugins file.`; if (Object.values(plugins).length === 0) { throw new Error(ERROR_MESSAGE); } const flowBuilderPlugin = Object.values(plugins).find(plugin => plugin.constructor.name === FLOW_BUILDER_PLUGIN_NAME); if (!flowBuilderPlugin) { throw new Error(ERROR_MESSAGE); } return flowBuilderPlugin; } exports.getFlowBuilderPlugin = getFlowBuilderPlugin; //# sourceMappingURL=helpers.js.map