Skip to content

Commit

Permalink
[Maintenance] Move the Stack's app related code under the app/ dire…
Browse files Browse the repository at this point in the history
…ctory (#5)

Every "demo" code like custom Twig Components, controllers, etc. should
be placed under the `app/` directory.
  • Loading branch information
jakubtobiasz authored Apr 23, 2024
2 parents 8561ae8 + c3e633d commit fc6b05f
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 5 deletions.
File renamed without changes.
4 changes: 1 addition & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,8 @@
}
},
"autoload-dev": {
"classmap": [
"src/Kernel.php"
],
"psr-4": {
"App\\": "app/",
"TestApplication\\Sylius\\TwigHooks\\": "src/TwigHooks/tests/Functional/.application/src/",
"Tests\\Sylius\\TwigHooks\\": "src/TwigHooks/tests/"
}
Expand Down
27 changes: 25 additions & 2 deletions config/services.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,29 @@
# Put parameters here that don't need to change on each machine where the app is deployed
# https://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration
parameters:
locale: en_US

services:
# Default configuration for services in *this* file
_defaults:
autowire: false
autoconfigure: false
# Automatically injects dependencies in your services
autowire: true

# Automatically registers your services as commands, event subscribers, etc.
autoconfigure: true

# Allows optimizing the container by removing unused services; this also means
# fetching services directly from the container via $container->get() won't work
public: false

# Makes classes in src/ available to be used as services;
# this creates a service per class whose id is the fully-qualified class name
App\:
resource: '../app/*'
exclude: '../app/{Entity,Migrations,Tests,Kernel.php}'

# Controllers are imported separately to make sure services can be injected
# as action arguments even if you don't extend any base controller class
# App\Controller\:
# resource: '../src/Controller'
# tags: ['controller.service_arguments']

0 comments on commit fc6b05f

Please sign in to comment.