2021-10-17 18:26:00 +02:00
|
|
|
---
|
2021-12-27 17:33:49 +01:00
|
|
|
title: "@freesewing/plugin-mirror"
|
2021-10-17 18:26:00 +02:00
|
|
|
---
|
2021-08-25 16:09:31 +02:00
|
|
|
|
2022-02-19 08:04:25 +01:00
|
|
|
The **@freesewing/plugin-mirror** plugin provides [the mirror
|
2021-12-27 17:33:49 +01:00
|
|
|
macro](/reference/api/macros/mirror) which facilitates mirroring
|
|
|
|
a number of points and/or paths around a given mirror line.
|
2021-08-25 16:09:31 +02:00
|
|
|
|
2021-12-27 17:33:49 +01:00
|
|
|
<Example part="plugin_mirror">Example of the mirror plugin</Example>
|
2021-08-25 16:09:31 +02:00
|
|
|
|
|
|
|
## Installation
|
|
|
|
|
|
|
|
```bash
|
|
|
|
npm install @freesewing/plugin-mirror
|
|
|
|
```
|
|
|
|
|
|
|
|
## Usage
|
|
|
|
|
2021-12-27 17:33:49 +01:00
|
|
|
Like all [build-time plugins](/guides/plugins/types-of-plugins#build-time-plugins), you
|
|
|
|
load them by passing them to the [freesewing.Design](/reference/api/design) super-constructor:
|
2021-08-25 16:09:31 +02:00
|
|
|
|
|
|
|
```js
|
|
|
|
import freesewing from "@freesewing/core";
|
|
|
|
import mirror from "@freesewing/plugin-mirror";
|
|
|
|
import config from "../config";
|
|
|
|
|
|
|
|
const Pattern = new freesewing.Design(config, mirror);
|
|
|
|
```
|
|
|
|
|
2021-12-27 17:33:49 +01:00
|
|
|
You can now use the [mirror](/reference/api/macros/mirror) macro in your parts.
|