PHPackages                             precision-soft/symfony-json-form - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. precision-soft/symfony-json-form

ActiveSymfony-bundle[Parsing &amp; Serialization](/categories/parsing)

precision-soft/symfony-json-form
================================

forms that serialize to json for frontend frameworks with symfony api backends

v1.0.3(1mo ago)019MITTypeScriptPHP &gt;=8.2

Since Sep 18Pushed 1mo agoCompare

[ Source](https://github.com/precision-soft/symfony-json-form)[ Packagist](https://packagist.org/packages/precision-soft/symfony-json-form)[ Docs](https://github.com/precision-soft/symfony-json-form)[ RSS](/packages/precision-soft-symfony-json-form/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (16)Versions (5)Used By (0)

Symfony json form
=================

[](#symfony-json-form)

**You may fork and modify it as you wish**.

Any suggestions are welcomed.

Purpose
-------

[](#purpose)

The purpose of this library is to create forms for single page applications, with a symfony backend. The forms are constructed in the backend and serialized to json, that can be rendered in the frontend. In the assets folder you can find a react component to render the form. There are 2 versions of the form:

- [formV1](./assets/react/formV1), is the original react components for rendering the form, kept for backwards compatibility.
- [formV2](./assets/react/formV2), the new components and the recommended way to render the json.

Usage
-----

[](#usage)

Add this to your **services.yaml**.

```
services:
    _instanceof:
        PrecisionSoft\Symfony\JsonForm\Service\Contract\AbstractFormService:
            calls:
                - [ setSerializer, [ '@serializer' ] ]
```

```
