Developer corner
Target group: Developers, Integrators
Table of Contents
Using the API
The API can be used like described in the schema manual. Use the 
        Type for instantiating a model type
class:
        EXT:my_extension/Classes/Controller/MyController.php
    
<?php
declare(strict_types=1);
namespace MyVendor\MyExtension\Controller;
use Brotkrueml\Schema\Type\TypeFactory;
final class MyController
{
    public function __construct(
        private readonly TypeFactory $typeFactory,
    ) {
    }
    public function doSomething(): void
    {
        // ...
        $drug = $this->typeFactory->create('Drug');
        // ...
    }
}
Using the view helpers
The Fluid view helpers can be used like described in the schema manual:
<schema:type.drug
   -id="https://example.org/#some-drug"
   name="some drug"
/>        
        Copied!
    
The Fluid namespace 
        schema is the same as for the core vocabulary.