跳到主要内容

代码片段

A Snippet is a reusable bit of markup that draws graphic elements on patterns. 代码片段 are provided by plugins and are implemented as defs elements in the rendered SVG document.

Signature

To place a Snippet at a given point:

const snippet = new Snippet(String 'snippet name', Point anchor)
RELATED

See the Snippet API for more information about how to use 代码片段 in code.

See Using Attributes for information about custom Attributes that can be used with 代码片段.

List of snippets

Below are all the different snippets we maintain.