1
0
Fork 0

feat: Flat import of markdown repo

This is a flat (without history) import of (some of) the content
from our markdown module.

We've imported this without history because the repo contains our
blog posts and showcases posts content prior to porting them to strapi.

Since this contains many images, it would balloon the size of this repo
to import the full history.

Instead, please refer to the history of the (archived) markdown repo
at: https://github.com/freesewing/markdown
This commit is contained in:
Joost De Cock 2021-08-25 16:09:31 +02:00
parent 1671a896b5
commit b34a2ee2ed
6132 changed files with 244167 additions and 0 deletions

View file

@ -0,0 +1,39 @@
---
title: Part dependencies
for: developers
about: Shows you how to create dependencies between pattern parts
---
Part dependencies are set in the [pattern configuration](/config), and
control the order in which parts are drawn. FreeSewing will make sure
that before drafting a part, it will first draft all its dependencies.
Let's look at an example:
```js
dependencies: {
front: "base",
back: "base",
sleeve: ["front", "back"]
}
```
This could be from a T-shirt pattern where the `front` and `back` patterns are very similar,
so they both are inheriting a `base` part.
In addition, the `sleeve` part needs to be drafted after the `front` and `back` part because
in `front` and `back` we store the length of the armhole seam in the [store](/api/store) and
we need that info to fit the sleevecap to the armhole.
Now if a user requests to draft only the `sleeve` part, FreeSewing will still draft:
- First the `base` part
- Then the `front` and `back` parts
- Finally the `sleeve` part
but it will only render the `sleeve` part, as that's the only thing the user requested.
<Note>
For inheriting parts, please refer to [part inheritance](/howtos/core/inject/).
</Note>