Automattic / Automattic/jetpack

Packages: Decouple any non-package functionality

Open
#12,686 1 comment 0 reactions 0 assignees View on GitHub
[Focus] Jetpack DNA Enhancement
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

#### Is your feature request related to a problem? Please describe.
Currently, in `/packages` we have a lot of references to functionality and code that lives outside `/packages`. Ideally, in a package, we should reference code that lives in a package.

The main rationale behind this is that we want any package to be independently reusable in another plugin (for example, VaultPress).

#### Describe the solution you'd like
* Move more code from Jetpack (the plugin) to independent, reusable packages.
* Migrate non-independent code from packages to use code only from packages.

This requires additional refactors as we go, including:
* Removing static calls in favor of ones in an object context.
* Moving code to packages and modernizing it
* Fixing references to old code
* Fixing old tests

Finally, let's make sure we deprecate old code properly and we don't break anything that depends on the old code.

#### Describe alternatives you've considered
None, we have to deal with this to be able to use the more complex packages externally.

#### Additional context
Part of the Jetpack DNA project - p1HpG7-70O-p2

Contributor guide

Open the contributing guide

Research direction

Start at /packages by inventorying references to code outside that directory, then trace the affected old tests and deprecations. The issue is complete when packages can be reused independently and compatibility with old code is preserved, but it does not identify a bounded package or specific test.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.