Files
agent_test/node_modules/daisyui/functions/plugin.js

12 lines
344 B
JavaScript
Raw Normal View History

2026-03-08 23:40:18 +07:00
export const plugin = {
withOptions: (pluginFunction, configFunction = () => ({})) => {
const optionsFunction = (options) => {
const handler = pluginFunction(options)
const config = configFunction(options)
return { handler, config }
}
optionsFunction.__isOptionsFunction = true
return optionsFunction
},
}