jonobr1 / jonobr1/two.js

[Enhancement] Add Path.Compound Static Method

Open
#696 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
JavaScript
Stars
8.7k
Forks
463
Avg merge
2d 1h
Merged PRs (30d)
8

Description

Describe the feature you'd like
Create a static method on Two.Path to be able to combine any number different paths and return a new compound path.

const compound = Two.Path.compound(a, b, c, d);

Functionally the code would project every vertex and concatenate them together into one list of vertices.

Additional context
Related to the Boolean Operations issue: https://github.com/jonobr1/two.js/issues/596

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the Two.Path implementation and inspect the related Boolean Operations issue (#596) for context. The work is done when a static Path.compound method accepts any number of paths, combines their vertices into one list, and returns a new compound path.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
computer-graphics
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.