devmachine / form-bundle
Set of Symfony form types.
Installs: 2 114
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Language:JavaScript
Type:symfony-bundle
Requires
- php: ^5.5|^7.0
- symfony/form: ^2.8|^3.0|^4.0
- symfony/framework-bundle: ^2.8|^3.0|^4.0
Requires (Dev)
- matthiasnoback/symfony-config-test: ~1.0
- matthiasnoback/symfony-dependency-injection-test: ^0.7
- phpunit/phpunit: ^4.0|^5.0|^6.0
- satooshi/php-coveralls: ~0.6
- symfony/twig-bridge: ^2.8|^3.0|^4.0
README
Symfony form extensions for Bootstrap date/datetime widgets, typeahead based autocomplete and other helpers.
Update 2017
In modern world of React, Angular and Vue there is no much point in solutions like this. Use your favourite front-end framework + Symfony API. However, you can still use this bundle if you want, see the demo for details.
Installation
Install this bundle using Composer. Add the following to your composer.json for Symfony 3.0+:
{ "require": { "devmachine/form-bundle": "~2.0" } }
Register bundle in the kernel:
<?php // app/AppKernel.php public function registerBundles() { $bundles = [ // ... new Devmachine\Bundle\FormBundle\DevmachineFormBundle(), ]; }
Integration
To add Javascript support to the form with devmachine type(s) form_javascript
twig block must be called.
{% extends 'AppBundle::layout.html.twig' %} {% block content %} {{ form_start(form) }} {{ form_widget(form) }} {{ form_end(form) }} {% endblock %} {# Put this block in parent template somewhere at the bottom of page. #} {% block javascripts %} {{ form_javascript(form) }} {% endblock %}
The approach used is same as in famous GenemuFormBundle.
Note: it is safe to use both DevmachineFormBundle and GenemuFormBundle in one project.
Documentation
Topics: