跳到主要内容

plugin-sprinkle

Published as @openclothes/plugin-sprinkle, this plugin provides the sprinkle macro which is a faster way to add several of the same snippets to your designs (think of it as sprinkling them onto your design).

Installation

npm install @openclothes/plugin-sprinkle

Usage

Either add it as a part plugins in your design, or add it to a pattern instance with Pattern.use().

To import the plugin for use:

import { sprinklePlugin } from '@openclothes/plugin-sprinkle'
// or
import { pluginSprinkle } from '@openclothes/plugin-sprinkle'

Notes

This plugin is part of the core-plugins bundle, so there is no need to install or import it manually unless you wish to forego loading of core plugins yet still want to load this plugin.