PHPackages                             woocommerce/woocommerce-example-package - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. woocommerce/woocommerce-example-package

AbandonedArchivedWordpress-plugin[Utility &amp; Helpers](/categories/utility)

woocommerce/woocommerce-example-package
=======================================

Example feature plugin package for WooCommerce.

v1.0.0(7y ago)972GPL-3.0-or-laterShell

Since Jun 25Pushed 7y agoCompare

[ Source](https://github.com/woocommerce/woocommerce-example-package)[ Packagist](https://packagist.org/packages/woocommerce/woocommerce-example-package)[ Docs](https://github.com/woocommerce/woocommerce-example-package)[ RSS](/packages/woocommerce-woocommerce-example-package/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (1)Dependencies (4)Versions (2)Used By (0)

WooCommerce Example Package
===========================

[](#woocommerce-example-package)

This is an example feature plugin package for WooCommerce. It is setup so that it can be installed standalone as a WordPress plugin, or included into another project/WooCommerce core as a Composer Package.

Installing Composer
-------------------

[](#installing-composer)

You need Composer to use the packages. If you don't have it installed, go and check how to [install Composer](https://github.com/woocommerce/woocommerce/wiki/How-to-set-up-WooCommerce-development-environment) and then continue here.

Installing packages
-------------------

[](#installing-packages)

Once you have defined your package requirements, run

```
composer install

```

and that will install the required Composer packages.

The example package has some package requirements defined:

- `"automattic/jetpack-autoloader"` - Handles autoloading and prevents version conflicts between packages.
- `"composer/installers"` - Allows the plugin to be installed via composer and moved to the correct install directory.
- `"phpunit/phpunit"` - Runs unit tests.
- `"woocommerce/woocommerce-sniffs"` - Checks for coding standards violations.

Main directories and files
--------------------------

[](#main-directories-and-files)

- `woocommerce-example-package.php` - The main plugin file. ONLY used when using this package as a plugin!
- `src/` - PSR-4 named classes under your namespace are placed here. Classes will be autoloaded.
- `src/Package.php` - The package class requires 3 static methods;
    - `init` - Init your package. If it needs to hook into WordPress, do so here.
    - `get_version` - Return the version of your package here. This will be used by WooCommerce in the system status report.
    - `get_path` - Return the package main directory. This will be used by WooCommerce in the system status report.
- `tests/` - Unit tests ran using `phpunit`.

Adding and running unit tests
-----------------------------

[](#adding-and-running-unit-tests)

Tests should be added in the `tests/Tests` directory.

You can run the tests by running the command

```
./vendor/bin/phpunit

```

from the plugin directory.

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2563d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d1f9b32f9677791fbef38b00c9225e05800f525b3b13872b118fd344a58350a0?d=identicon)[woocommerce](/maintainers/woocommerce)

![](https://www.gravatar.com/avatar/8295774fc174b6a5b9bd960709949f4de88cd0b8708d711dc5b6676693d41432?d=identicon)[mikejolley](/maintainers/mikejolley)

---

Top Contributors

[![mikejolley](https://avatars.githubusercontent.com/u/90977?v=4)](https://github.com/mikejolley "mikejolley (3 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/woocommerce-woocommerce-example-package/health.svg)

```
[![Health](https://phpackages.com/badges/woocommerce-woocommerce-example-package/health.svg)](https://phpackages.com/packages/woocommerce-woocommerce-example-package)
```

###  Alternatives

[helsingborg-stad/municipio

A bootstrap theme for creating municipality sites.

4028.5k10](/packages/helsingborg-stad-municipio)[mautic/core

Mautic Open Source Distribution

10.0k2.6k9](/packages/mautic-core)[mediawiki/maps

Adds various mapping features to MediaWiki

84152.3k3](/packages/mediawiki-maps)[starcitizentools/citizen-skin

A beautiful, usable, responsive MediaWiki skin with in-depth extension support. Originally developed for the Star Citizen Wiki.

3376.6k](/packages/starcitizentools-citizen-skin)[civicrm/civicrm-drupal-8

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

19251.4k2](/packages/civicrm-civicrm-drupal-8)[altis/core

Core module for Altis

19228.0k3](/packages/altis-core)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
