Skip to content

Commit

Permalink
Fixing indentations
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenvdlinde committed Mar 20, 2023
1 parent 04c369d commit 45dc48e
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,11 @@ This template is for rapid Symfony bundle development and meant as a model to ba
- Open composer.json, and change the name to your fitting. The first word should be the namespace, and the second the bundle's name.
> Note: this is kebab-case. Also read: [naming your package](https://packagist.org/about#naming-your-package)

- Check the autoload field to be set accordingly.
- Open PetStoreBundle.php and change the Bundle `name` and `namespace`. The namespace should be the same as your package name in `composer.json` but in CamelCase. So `common-gateway/pet-store-bundle` becomes `CommonGateway/PetStoreBundle`
- Rename the `/Service` and `/ActionHandler` accordingly (or delete if not used).
- Rename the `/DependencyInjection/PetStoreExtension.php` to your `BundleNameExtension.php`
- Rename the `/Resources/config/services.yaml` namespaces
- Check the autoload field to be set accordingly.
- Open PetStoreBundle.php and change the Bundle `name` and `namespace`. The namespace should be the same as your package name in `composer.json` but in CamelCase. So `common-gateway/pet-store-bundle` becomes `CommonGateway/PetStoreBundle`
- Rename the `/Service` and `/ActionHandler` accordingly (or delete if not used).
- Rename the `/DependencyInjection/PetStoreExtension.php` to your `BundleNameExtension.php`
- Rename the `/Resources/config/services.yaml` namespaces

### Adding schemas
You can load [json schemas](https://json-schema.org/learn/getting-started-step-by-step.html#starting-the-schema) as Entities from your [`/Schema`](https://github.com/CommonGateway/PetStoreBundle/tree/main/Schema) folder to use in the Common Gateway and work with objects based on your schemas.
Expand All @@ -68,15 +68,15 @@ You can add existing schemas or create your own and add them to the`/Schema` fol

The following properties are required, and without them, the Gateway won't recognize the schema as valid:

- `version` can start on '0.1.0.'
- `version` can start on '0.1.0.'
> without this property, you can't update schemes
- `$schema` (https://json-schema.org/draft/2020-12/schema)
- `$id` (https://opencatalogi.nl/{Your scheme name}.schema.json)
- `$schema` (https://json-schema.org/draft/2020-12/schema)
- `$id` (https://opencatalogi.nl/{Your scheme name}.schema.json)
> unique `$id` to be relatable to other schemas.
- `type` must be 'object'
- `properties` must be schema properties
- `type` must be 'object'
- `properties` must be schema properties


Once you add schemas to the repository, you can also add objects/data for those schemas. There is an example shown in the [`/Data`](https://github.com/CommonGateway/PetStoreBundle/tree/main/Data) folder.

0 comments on commit 45dc48e

Please sign in to comment.