![]() This PR reverts the incorrect lint/prettier changes applied to <Example> code in the reference Core API docs l by the husky pre-commit hook, the problem mentioned in Issue #333. (These are just the changes for the Core API docs. Additional PRs will be filed for changes in the other reference, howtos, and guides documentation.) Co-authored-by: Benjamin Fan <ben-git@swinglonga.com> Reviewed-on: https://codeberg.org/freesewing/freesewing/pulls/367 Reviewed-by: Joost De Cock <joostdecock@noreply.codeberg.org> Co-authored-by: Benjamin Fan <benjamesben@noreply.codeberg.org> Co-committed-by: Benjamin Fan <benjamesben@noreply.codeberg.org> |
||
---|---|---|
.. | ||
addclass | ||
addtext | ||
angleat | ||
aspathstring | ||
asrenderprops | ||
attr | ||
bbox | ||
circlesegment | ||
clean | ||
clone | ||
close | ||
combine | ||
curve | ||
curve_ | ||
divide | ||
edge | ||
end | ||
hide | ||
insop | ||
intersects | ||
intersectsbeam | ||
intersectsx | ||
intersectsy | ||
join | ||
length | ||
line | ||
move | ||
noop | ||
offset | ||
reverse | ||
rotate | ||
roughlength | ||
setclass | ||
sethidden | ||
settext | ||
shiftalong | ||
shiftfractionalong | ||
smurve | ||
smurve_ | ||
split | ||
start | ||
translate | ||
trim | ||
ucurve | ||
unhide | ||
readme.mdx |
--- title: Path --- A path represents an SVG path, which are the lines and curves on our pattern. ## Signature ```js Path new Path() ``` The Path constructor takes no arguments. ## Properties A Path object comes with the following properties: - `attributes` : An [Attributes](/reference/api/attributes) instance holding the path's attributes - `hidden` : When this is `true` the path will be hidden (excluding it from the output). See [Path.hide()](/reference/api/path/hide), [Path.unhide()](/reference/api/path/unhide), and [Path.setHidden()](/reference/api/path/sethidden) for various methods that allow setting this in a chainable way. :::note RELATED See [Using Attributes](/howtos/code/attributes) for information about custom Attributes that can be used with Paths. ::: ## Example <Example caption="Example of the Path contructor"> ```js ({ Point, points, Path, paths, part }) => { paths.example = new Path() .move(new Point(0,0)) .line(new Point(100,0)) return part } ``` </Example> ## Methods A Path object exposes the following methods: <ReadMore />