PHPackages                             hiwelo/raccoon-starter - 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. hiwelo/raccoon-starter

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

hiwelo/raccoon-starter
======================

Raccoon is a personal wordpress starter theme based on NPM, Babel ES-2015, Gulp and Knacss

27PHP

Since Jan 28Pushed 8y agoCompare

[ Source](https://github.com/hiwelo/raccoon-starter)[ Packagist](https://packagist.org/packages/hiwelo/raccoon-starter)[ RSS](/packages/hiwelo-raccoon-starter/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (3)Used By (0)

Raccoon WordPress starter
=========================

[](#raccoon-wordpress-starter)

**[Raccoon](https://github.com/hiwelo/raccoon/)** is a [*WordPress*](https://wordpress.org/) starter theme based on Composer &amp; NPM &amp; Babel (ES 2015 preset) &amp; Gulp &amp; Knacss.

[![Build Status](https://camo.githubusercontent.com/d06668c513d3ad828571810019bc7dda52c534dd96f55cbb402d8cfd181eeeec/68747470733a2f2f7472617669732d63692e6f72672f686977656c6f2f726163636f6f6e2e7376673f6272616e63683d646576656c6f70)](https://travis-ci.org/hiwelo/raccoon)

Summary
-------

[](#summary)

- [Requirements](#requirements)
- [Installation](#installation)
- [How to work with a raccoon](#how-to-work-with-a-raccoon)
    - [Before to work](#before-to-work)
    - [Vendor update](#vendor-update)
    - [Before to commit](#before-to-commit)
    - [Documentation](#documentation)
- [How to code with a raccoon](#how-to-code-with-a-raccoon)
    - [OOP PHP Class](#oop-php-class)
    - [Raccoon loves PSR-2 Coding Standards and documentation](#raccoon-loves-psr-2-coding-standards-and-documentation)
- [How a raccoon can help you with *WordPress*](#how-a-raccoon-can-help-you-with-wordpress)
    - [Configuration manifest](#configuration-manifest)
    - [*WordPress* theme namespace](#wordpress-theme-namespace)
    - [Theme supports](#theme-support)
    - [Theme features](#theme-features)
    - [Navigations](#navigations)
    - [Post Types](#post-types)
        - [Create a custom post type](#create-a-custom-post-type)
        - [Post type unregistration](#post-type-unregistration)
    - [Post Status](#post-status)
    - [Sidebars](#sidebars)
    - [Widgets](#widgets)
- [Third part features](#third-part-features)
    - [Raccoon loves Bedrock](#raccoon-loves-bedrock)

Requirements
------------

[](#requirements)

For its development, **[Raccoon](https://github.com/hiwelo/raccoon/)** requires:

- PHP &gt;= 5.6
- Composer
- Node.js with npm for package management
- WordPress &gt;= 4.4

Installation
------------

[](#installation)

It's pretty simple: you just have to clone the repository and run `composer install`to start all required jobs.

```
git clone https://github.com/hiwelo/raccoon.git
composer install

```

How to work with a raccoon
--------------------------

[](#how-to-work-with-a-raccoon)

### Before to work

[](#before-to-work)

Before any modification, please run:

```
composer work

```

With this command you verify that your repository is up to date and it starts all watch jobs.

### Vendor update

[](#vendor-update)

Regularly, don't forget to update all dependencies (composer &amp; npm) with:

```
composer update

```

### Before to commit

[](#before-to-commit)

After any modification and before you commit anything, I strongly advice to run:

```
composer test

```

And if there's no errors, you can commit your modifications.

If there's some errors and you absolutely want to commit, you've got to run this command to avoid pre-commit verifications:

```
git commit --no-verify

```

### Documentation

[](#documentation)

If you want to parse all PHP files to generate the documentation, please run:

```
composer documentation

```

The generated documentation is available in the `./docs/api/` folder.

How to code with a raccoon
--------------------------

[](#how-to-code-with-a-raccoon)

### OOP PHP Class

[](#oop-php-class)

**[Raccoon](https://github.com/hiwelo/raccoon/)** is an OOP-based *WordPress* template. All **[Raccoon](https://github.com/hiwelo/raccoon/)**'s classes are placed within the namespace `Hwlo\Raccoon\` and you can find them in the `./lib` directory.

Any custom class that you can create should be placed in a specific namespace. For example, you can use a namespace like `Hwlo\Raccoon\Custom\`.

When you create a new namespace, you have to add it in the `composer.json` file, in the `autoload` section. I strongly advice to use a PSR-4 namespace.

For example, if you want to register a custom namespace like `Hwlo\Raccoon\Custom\`, you have to write custom classes in `./custom-lib/` and update `composer.json` like that:

```
{
  "autoload": {
    "psr-4": {
      "Hwlo\\Raccoon\\": "./lib/",
      "Hwlo\\Raccoon\\Custom\\": "./custom-lib/"
    }
  }
}
```

For each new created class, you may need to regenerate the `./vendor/autoload.php` file. For this operation, please run:

```
composer autoload

```

### **[Raccoon](https://github.com/hiwelo/raccoon/)** loves PSR-2 Coding Standards and documentation

[](#raccoon-loves-psr-2-coding-standards-and-documentation)

When a raccoon work, he likes to make sure his work can be understood by all. So he writes scripts which are conform to standards used by the PHP community.

**[Raccoon](https://github.com/hiwelo/raccoon/)** uses [PSR-2 Coding Standards](http://www.php-fig.org/psr/psr-2/) for its tests. Each modification must make a successful *PSR-2* syntax check to be committed. So, Raccoon have got just a little modification : scripts documentation is required by the `ruleset.xml` for *PHP CS* validation.

You can run at any time a test control on all PHP &amp; JavaScript files with:

```
composer test

```

Some errors on PHP files can be automatically fixed by `phpcbf`. To do so, run:

```
composer phpcbf

```

So don't forget: to make **[Raccoon](https://github.com/hiwelo/raccoon/)** happy, document your *f\*\*king* code! :D

How a raccoon can help you with *WordPress*
-------------------------------------------

[](#how-a-raccoon-can-help-you-with-wordpress)

### Configuration manifest

[](#configuration-manifest)

To avoid multiple initialization functions, **[Raccoon](https://github.com/hiwelo/raccoon/)** uses a *JSON* configuration file: `manifest.json`. In this file you can set all features proposed by *WordPress* to its themes.

### *WordPress* theme namespace

[](#wordpress-theme-namespace)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can define a specific namespace for this theme. This namespace will be mainly used by string translation methods like `__()` or `_e()` or `_x()` or `_n()`.

To define a specific namespace, you have to update `manifest.json` like that:

```
{
  "namespace": "raccoon"
}
```

If empty or undefined, the default namespace will be `raccoon`.

### Theme support

[](#theme-support)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can easily set up all theme features with the `manifest.json` file.

All features described in the [*WordPress* documentation](https://codex.wordpress.org/Function_Reference/add_theme_support) can be registered with or without arguments. Considering the JSON format, a feature requires a least a boolean.

Here is the kind of statements that you can set up in the `manifest.json` file:

```
{
  "theme-support": {
    "title-tag": true,
    "post-thumbnail": true,
    "automatic-feed-links": true,
    "post-formats": [
      "link",
      "quote",
      "audio",
      "video"
    ],
    "html5": [
      "caption",
      "comment-form",
      "comment-list",
      "gallery",
      "search-form"
    ]
  }
}
```

### Theme features

[](#theme-features)

**[Raccoon](https://github.com/hiwelo/raccoon)** has a feature which allows you to disable some Wordpress features like widgets or comments. In the `manifest.json` file you can easily (de-)activate these features with:

```
{
  "theme-features": {
    "comments": false,
    "widget": false
  }
}
```

### Navigations

[](#navigations)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can easily set up navigations with the `manifest.json` file.

Each navigation must have a location and a readable description like in the [*WordPress* documentation](https://codex.wordpress.org/Function_Reference/register_nav_menu).

For example if you want to register two navigations (a primary navigation and a list of social networks), you have to update `manifest.json` like that:

```
{
  "navigations": {
    "primary": "Main navigation",
    "social": "Social links"
  }
}
```

### Post Types

[](#post-types)

#### Create a custom post type

[](#create-a-custom-post-type)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can easily set up custom post types with the `manifest.json` file.

Each custom post type must have a title and an array of arguments. All arguments described in the [*WordPress* documentation](https://codex.wordpress.org/Function_Reference/register_post_type) can be used in the `manifest.json` file.

For example if you want to register the same post type as the [*WordPress* documentation](https://codex.wordpress.org/Function_Reference/register_post_type#_edit_link), you have to update `manifest.json` like that:

```
{
  "post-types": {
    "books": {
      "labels": {
        "name": "Books",
        "singular_name": "Book",
        "menu_name": "Books",
        "name_admin_bar": "Book",
        "add_new": "Add New",
        "add_new_item": "Add New Book",
        "new_item": "New Book",
        "edit_item": "Edit Book",
        "view_item": "View Book",
        "all_items": "All Books",
        "search_items": "Search Books",
        "parent_item_colon": "Parent Books:",
        "not_found": "No books found.",
        "not_found_in_trash": "No books found in Trash."
      },
      "description": "Description.",
      "public": "true",
      "publicly_queryable": "true",
      "query_var": "true",
      "rewrite": {
        "slug": "book"
      },
      "menu_icon": "dashicons-editor-paragraph",
      "supports": [
        "title",
        "editor",
        "author",
        "thumbnail",
        "excerpt",
        "custom-fields",
        "revisions",
        "post-formats"
      ]
    }
  }
}
```

Good to know, you can't declare in `manifest.json` a custom post type named *remove*.

#### Post type unregistration

[](#post-type-unregistration)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can alse easily unregister an existing post type with the `manifest.json` file.

Each existing post type, event *post* or *pages* can be unregister with this `manifest.json` functionality. You just have to add in your `manifest.json`:

```
{
  "post-types": {
    "remove": ["post"]
  }
}
```

For example if you want to register the same post type as the [*WordPress* documentation](https://codex.wordpress.org/Function_Reference/register_post_type#_edit_link), you have to update `manifest.json` like that:

### Post Status

[](#post-status)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can easily set up custom post status with the `manifest.json` file. Each custom post status will be automatically added into each admin panel page inside post status selectboxes.

Each custom post status can have all arguments described for the [WordPress `register_post_status()` method](https://codex.wordpress.org/Function_Reference/register_post_status).

For example, if you want to register a new custom post status, you have to update `manifest.json` like that:

```
{
  "post-status": {
    "archive": {
      "label": "Archive",
      "exclude_from_search": false,
      "public": false,
      "internal": false,
      "protected": true,
      "private": false,
      "publicly_queryable": false,
      "show_in_admin_all_list": true,
      "show_in_admin_status_list": true,
      "_builtin": true,
      "label_count": [
        "Archive (%s)",
        "Archives (%s)"
      ]
    }
  }
}
```

Good to know, you can't declare in `manifest.json` a custom post status named *remove*.

### Sidebars

[](#sidebars)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can easily set up sidebars with the `manifest.json` file.

Each sidebar must have an array of arguments. All arguments described in the [*WordPress* documentation](https://codex.wordpress.org/Function_Reference/register_sidebar) can be used in the `manifest.json` file.

For example if you want to register the same sidebar as the [*WordPress* documentation](https://codex.wordpress.org/Function_Reference/register_sidebar), you have to update `manifest.json` like that:

```
{
  "sidebars": [
    {
      "name": "Sidebar name",
      "id": "unique-sidebar-id",
      "description": "Description.",
      "class": "sidebarClassName",
      "before_widget": "",
      "after_widget": "",
      "before_title": "",
      "after_title": ""
    }
  ]
}
```

### Widgets

[](#widgets)

With **[Raccoon](https://github.com/hiwelo/raccoon/)**, you can easily set up widgets with the `manifest.json` file.

Each widget must consist of a specific OOP PHP Class like described in the [*WordPress* documentation](https://codex.wordpress.org/Widgets_API). So, for a [widget registration](https://codex.wordpress.org/Function_Reference/register_sidebar) you just have to add the widget classname in the `manifest.json`, with its complete namespace like that:

```
{
  "widgets": [
    "Hwlo\\Raccoon\\WidgetExample"
  ]
}
```

Third-part features
-------------------

[](#third-part-features)

### Raccoon loves Bedrock

[](#raccoon-loves-bedrock)

*[Bedrock](https://roots.io/bedrock/)* is a *WordPress* boilerplate which create a better projet structure mainly with a new `wp-content/` folder renamed `app/`. *[Bedrock](https://roots.io/bedrock/)* use Composer and environments variables.

By example, **[Raccoon](https://github.com/hiwelo/raccoon/)** can use environments variables from Bedrocks to know the environment status (development, production, staging) and manage which debug informations has to be returned by the theme. If you don't use *[Bedrock](https://roots.io/bedrock/)*, you can manually set environment status in the `manifest.json` file like this :

```
{
  "environment-status": "development"
}
```

###  Health Score

21

—

LowBetter than 18% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity44

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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/4989733?v=4)[Damien Senger](/maintainers/hiwelo)[@hiwelo](https://github.com/hiwelo)

---

Top Contributors

[![hiwelo](https://avatars.githubusercontent.com/u/4989733?v=4)](https://github.com/hiwelo "hiwelo (158 commits)")

### Embed Badge

![Health badge](/badges/hiwelo-raccoon-starter/health.svg)

```
[![Health](https://phpackages.com/badges/hiwelo-raccoon-starter/health.svg)](https://phpackages.com/packages/hiwelo-raccoon-starter)
```

###  Alternatives

[peppeocchi/php-cron-scheduler

PHP Cron Job Scheduler

8292.6M37](/packages/peppeocchi-php-cron-scheduler)

PHPackages © 2026

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