- Howtos
- Common code challenges
- Part inheritance
Part inheritance
Part inheritance means that rather than start your part from a blank slate, your starting point is another part. You will inherit all its points, paths, and snippets, hence the name.
WARNING|
Do not confuse this with part dependencies.
Part inheritance is configured with the from
keyword. Let’s look at an
example:
Javascript
import { front as brianFront } from '@freesewing/brian'
export const front = {
name: 'example.front',
from: brianFront,
draft: function ({ part }
) {
// Design part here
return part
}
}
TIP
Refer to the part documentation on dependencies for all details.