Sylius / PluginSkeleton

Skeleton for starting Sylius plugins.
https://sylius.com/plugins/
73 stars 63 forks source link
hacktoberfest sylius sylius-plugin

Plugin Skeleton

Skeleton for starting Sylius plugins.

Documentation

For a comprehensive guide on Sylius Plugins development please go to Sylius documentation, there you will find the Plugin Development Guide, that is full of examples.

Quickstart Installation

Traditional

  1. Run composer create-project sylius/plugin-skeleton ProjectName.

  2. From the plugin skeleton root directory, run the following commands:

    $ (cd tests/Application && yarn install)
    $ (cd tests/Application && yarn build)
    $ (cd tests/Application && APP_ENV=test bin/console assets:install public)
    
    $ (cd tests/Application && APP_ENV=test bin/console doctrine:database:create)
    $ (cd tests/Application && APP_ENV=test bin/console doctrine:schema:create)

To be able to set up a plugin's database, remember to configure you database credentials in tests/Application/.env and tests/Application/.env.test.

Docker

  1. Execute docker compose up -d

  2. Initialize plugin docker compose exec app make init

  3. See your browser open localhost

Usage

Running plugin tests

Opening Sylius with your plugin