Slide 1

Slide 1 text

Sylius An E-Commerce Solution Symfony Based https://www.linkedin.com/in/sergiosicari/ https://github.com/sergioska Sergio Sicari Senior Backend Developer / DevOps (PED)

Slide 2

Slide 2 text

E-commerce Solutions ● CMS ○ Wordpress + WooCommerce ○ PrestaShop ○ Magento ● Custom Implementation ○ ?????

Slide 3

Slide 3 text

CMS vs Custom Implementation CMS Custom Implementation ● Ready To Go ● Cheap startup ● Bed Coding ● Extension can be expensive (magento) ● High Customization Level ● Code Quality ● Long implementation time

Slide 4

Slide 4 text

What is Sylius? Sylius is an open source e-commerce solution Symfony framework based ● Components approach ● Flexibility ● Easy customization ● BDD approach (Behavior Driven Development) ● Good quality code

Slide 5

Slide 5 text

Three nature of Sylius Sylius can be considered ● a collection of decoupled and flexible components ● a set of symfony bundle which integrate the components ● a complete e-commerce platform that implement all above E-commerce Framework (Sylius) Symfony Bundle Component

Slide 6

Slide 6 text

Architecture Sylius Components Bundles Core Admin Shop API

Slide 7

Slide 7 text

Components, Bundles And Platform Sylius Components Bundles Core Admin Shop API ● Components Every single component of Sylius can be used in standalone because it’s fully decoupled. Taxation component “know” only know how to calculate taxes ● Bundles Symfony bundles. TaxationBundle use taxation component and give access also services, models, ...

Slide 8

Slide 8 text

Under The Hood

Slide 9

Slide 9 text

Let’s try to install only a component

Slide 10

Slide 10 text

Using a component

Slide 11

Slide 11 text

Admin, Shop And Api Sylius Components Bundles Core Admin Shop API ● Admin AdminBundle gives backoffice features to e-commerce administration ● Shop ShopBundle implements a standard B2C interface ● Api AdminApiBundle is an REST API set that operate from Admin perspective

Slide 12

Slide 12 text

Prerequisites ● Unix like system (MacOS or Linux) ● PHP >= 7.2 ● MySQL ● Composer ● Yarn

Slide 13

Slide 13 text

Getting started # create symfony project $ composer create-project sylius/sylius-standard MyFirstShop $ cd MyFirstShop # install sylius $ bin/console sylius:install # install assets $ yarn install $ yarn build # check installation $ symfony serve $ open http://127.0.0.1:8000/admin

Slide 14

Slide 14 text

Dashboard Backoffice

Slide 15

Slide 15 text

No content

Slide 16

Slide 16 text

Shop

Slide 17

Slide 17 text

In The Real World

Slide 18

Slide 18 text

Customizations ● Models ● Forms ● Repositories ● Factories ● Controllers ● Validations ● Menu ● Templates ● Translations ● State Machines ● Grids ● Fixtures

Slide 19

Slide 19 text

Plugin Store Extend functionality using plugin: Install via composer composer require sylius/shop-api- plugin

Slide 20

Slide 20 text

Standalone E-Commerce E-Commerce Shop Api Plugin Main App Sylius JWT Rest API Call Serialized Data

Slide 21

Slide 21 text

Shop Api Plugin Calls

Slide 22

Slide 22 text

References Sylius Documentation https://docs.sylius.com/en/1.6/index.html Shop Api Plugin https://github.com/Sylius/ShopApiPlugin Slack channel https://sylius-slackin.herokuapp.com/

Slide 23

Slide 23 text

Thank You! Questions? https://www.linkedin.com/in/sergiosicari/ https://github.com/sergioska Sergio Sicari Senior Backend Developer / DevOps (PED)

Slide 24

Slide 24 text

PUG Catania - Join Us Telegram t.me/pugct Facebook https://www.facebook.com/groups/PUGCT/ Meetup https://www.meetup.com/it-IT/pugCatania-PHP-User-Group-Catania Sito Web https://catania.grusp.org

Slide 25

Slide 25 text

PUG Catania - Join Us Telegram t.me/pugct Facebook https://www.facebook.com/groups/PUGCT/ Meetup https://www.meetup.com/it-IT/pugCatania-PHP-User-Group-Catania Sito Web https://catania.grusp.org