Skip to content

Commit 3bf990e

Browse files
committed
autoconfigure is needed for routing.route_loader tag
1 parent 7e39d65 commit 3bf990e

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Loads routes in Symfony based on [OpenAPI/Swagger annotations](https://github.com/zircote/swagger-php).
44

5-
![CI](https://github.com/Tobion/OpenAPI-Symfony-Routing/workflows/CI/badge.svg)
5+
[![CI](https://github.com/Tobion/OpenAPI-Symfony-Routing/workflows/CI/badge.svg)](https://github.com/Tobion/OpenAPI-Symfony-Routing/actions)
66

77
## Installation
88

@@ -42,10 +42,8 @@ This library provides an `OpenApiRouteLoader` that you need to define as service
4242
```yaml
4343
# config/services.yaml
4444
services:
45-
_defaults:
46-
autoconfigure: true
47-
4845
Tobion\OpenApiSymfonyRouting\OpenApiRouteLoader:
46+
autoconfigure: true
4947
# Looks for OpenAPI/Swagger annotations in the symfony flex default "src" directory
5048
factory: [Tobion\OpenApiSymfonyRouting\OpenApiRouteLoader, fromSrcDirectory]
5149
```
@@ -66,6 +64,7 @@ openapi_routes:
6664
```yaml
6765
services:
6866
Tobion\OpenApiSymfonyRouting\OpenApiRouteLoader:
67+
autoconfigure: true
6968
factory: [Tobion\OpenApiSymfonyRouting\OpenApiRouteLoader, fromDirectories]
7069
arguments:
7170
- '%kernel.project_dir%/src'

0 commit comments

Comments
 (0)