1
0
Fork 0

chore: Linting for markdown and js

This commit is contained in:
joostdecock 2021-10-17 17:34:55 +02:00
parent eca8199ed8
commit 1c92e0f655
6677 changed files with 24391 additions and 25987 deletions

View file

@ -1,12 +1,13 @@
---
***
title: Macros
order: 90
---
---------
Plugin structure for macros is similar, with a few changes:
- Rather than the hook name, you provide the macro name (that you choose yourself)
- The context (`this`) of a macro method is **always** a [Part](/reference/api/part) object.
* Rather than the hook name, you provide the macro name (that you choose yourself)
* The context (`this`) of a macro method is **always** a [Part](/reference/api/part) object.
Apart from these, the structure is very similar:
@ -35,7 +36,7 @@ export default {
}
```
Did you figure out what this plugin does?
Did you figure out what this plugin does?
It provides a `box` macro that draws a box on our pattern in a given location with a give size.
We can use it like this:
@ -48,7 +49,7 @@ macro('box', {
});
```
Obviously, you can expect to learn how to call a macro in its documentation,
Obviously, you can expect to learn how to call a macro in its documentation,
rather than have to comb through its code.
<Note>
@ -61,4 +62,3 @@ to a macro needs to be contained in a single argument.
Typically, you use a single plain object to configure the macro.
</Note>