BoltCM

Sophisticated, Lightweight and Simple

Jump to docs navigation
Edit on GitHub

Note: You are currently reading the documentation for Bolt 3.0. Looking for the documentation for Bolt 3.2 instead?

Marketplace » Composer.json

Each extension or theme requires a composer.json, which holds some important meta data. That meta data includes information like name, author, keywords, icon, screenshots and so on.

For extensions, it also includes information about the extension class and the public assets folder.

Example composer.json for Themes

{
    "name": "dropbear/jungle",
    "description": "Full responsive blog template in jungle style",
    "type": "bolt-theme",
    "keywords": ["jungle", "responsive", "blog", "modern"],
    "require": {
        "bolt/bolt": "^3.0"
    },
    "license": "MIT",
    "authors": [
        {
            "name": "Kenny Koala",
            "email": "kenny@dropbear.com.au"
        }
    ],
    "extra": {
        "bolt-icon": "icon.png",
        "bolt-screenshots": [
            "screenshots/teaser.png",
            "screenshots/screenshot1.png",
            "screenshots/screenshot2.png"
        ]
    }
}

Example composer.json for Extensions

{
    "name": "dropbear/koala-catcher",
    "description": "Catching koalas like a Pro",
    "type": "bolt-extension",
    "keywords": ["dropbear", "dangerous"],
    "require": {
        "bolt/bolt": "^3.0"
    },
    "license": "MIT",
    "authors": [
        {
            "name": "Kenny Koala",
            "email": "kenny@dropbear.com.au"
        }
    ],
    "autoload": {
        "psr-4": {
            "Bolt\\Extension\\DropBear\\KoalaCatcher\\": "src"
        }
    },
    "extra": {
        "bolt-assets": "web",
        "bolt-class": "Bolt\\Extension\\DropBear\\KoalaCatcher\\KoalaCatcherExtension",
        "bolt-icon": "icon.png",
        "bolt-screenshots": [
            "screenshots/teaser.png",
            "screenshots/screenshot1.png",
            "screenshots/screenshot2.png"
        ]
    }
}

General Required Fields

Additional Extension Required Fields

General Optional Fields


Couldn't find what you were looking for? We are happy to help you in the forum, on Slack or on IRC.
Spotted a typo, or have something to add? Edit this page on GitHub.