PHPackages                             jaxon-php/jaxon-symfony - 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. [Framework](/categories/framework)
4. /
5. jaxon-php/jaxon-symfony

ActiveLibrary[Framework](/categories/framework)

jaxon-php/jaxon-symfony
=======================

Jaxon library integration for the Symfony Framework

v5.0.5(9mo ago)31.3k3BSD-3-ClausePHP

Since Oct 16Pushed 9mo ago2 watchersCompare

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

READMEChangelog (10)Dependencies (4)Versions (44)Used By (0)

Jaxon integration for Symfony
=============================

[](#jaxon-integration-for-symfony)

This package is an extension to integrate the [Jaxon library](https://github.com/jaxon-php/jaxon-core) into the Symfony framework. It works with Symfony version 5 or newer.

Installation
------------

[](#installation)

Add the following lines in the `composer.json` file, and run the `composer update jaxon-php/` command.

```
"require": {
    "jaxon-php/jaxon-symfony": "^5.0"
}
```

Add the Jaxon bundle in the `config/bundle.php` file.

```
return [
    ...

    Jaxon\Symfony\JaxonBundle::class => ['all' => true],
];
```

Configuration
-------------

[](#configuration)

The library configuration is located in the `packages/config/jaxon.yaml` file. It must contain both the `app` and `lib` sections defined in the documentation ().

An example is presented in the `config/jaxon.yaml` file of this repo.

Add the following settings in the `config/services.yaml` file, to configure the Jaxon library.

```
imports:
    ...
    - { resource: packages/jaxon.yaml }
```

Add the following settings in the `config/routes.yaml` file, to configure the Jaxon route.

```
jaxon_ajax:
    resource: 'Jaxon\Symfony\App\Jaxon::route'
    type: service
```

Routing and listener
--------------------

[](#routing-and-listener)

The extension provides a route and a controller to process Jaxon Ajax requests, as well as a listener on the `kernel.controller` event to bootstrap the Jaxon library.

Dependency injection
--------------------

[](#dependency-injection)

Services in Symfony can be declared as public or private, and [injected in Jaxon classes](https://www.jaxon-php.org/docs/v3x/advanced/dependency-injection.html).

Since Jaxon uses a container to fetch to the Symfony services that are injected in his classes, by default it will be able to get access only to services declared as public.

A service locator can be defined for Jaxon in the `config/services.yaml` file, in order to provide access to private services.

```
services:
  ...
    jaxon.service_locator:
        public: true
        class: Symfony\Component\DependencyInjection\ServiceLocator
        tags: ['container.service_locator']
        arguments:
            -
                Twig\Environment: '@twig'
```

The service locator must be declared as public, and take all the services that can be passed to Jaxon classes as arguments. See the [Symfony service locators documentation](https://symfony.com/doc/4.4/service_container/service_subscribers_locators.html).

Twig functions
--------------

[](#twig-functions)

This extension provides the following Twig functions to insert Jaxon js and css codes in the pages that need to show Jaxon related content.

```
// templates/demo/index.html.twig

{{ jxnCss() }}

{{ jxnJs() }}

{{ jxnScript() }}
```

Call factories
--------------

[](#call-factories)

This extension registers the following Twig functions for Jaxon [call factories](https://www.jaxon-php.org/docs/v5x/ui-features/call-factories.html) functions.

Note

In the following examples, the `rqAppTest` template variable is set to the value `rq(Demo\Ajax\App\AppTest::class)`.

The `jxnBind` function attaches a UI component to a DOM element, while the `jxnHtml` function displays a component HTML code in a view.

```

        {{ jxnHtml(rqAppTest) }}

```

The `jxnPagination` function displays pagination links in a view.

```

```

The `jxnOn` function binds an event on a DOM element to a Javascript call defined with a `call factory`.

```

        Black
        Red
        Green
        Blue

```

The `jxnClick` function is a shortcut to define a handler for the `click` event.

```
    Click me
```

The `jxnEvent` function defines a set of events handlers on the children of a DOM element, using `jQuery` selectors.

```

                Black
                Red
                Green
                Blue

                Black
                Red
                Green
                Blue

```

The `jxnEvent` function takes as parameter an array in which each entry is an array with a `jQuery` selector, an event and a `call factory`.

Contribute
----------

[](#contribute)

- Issue Tracker: github.com/jaxon-php/jaxon-symfony/issues
- Source Code: github.com/jaxon-php/jaxon-symfony

License
-------

[](#license)

The package is licensed under the BSD license.

###  Health Score

45

—

FairBetter than 92% of packages

Maintenance56

Moderate activity, may be stable

Popularity22

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity76

Established project with proven stability

 Bus Factor1

Top contributor holds 99.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~78 days

Recently: every ~6 days

Total

42

Last Release

292d ago

Major Versions

v1.0.x-dev → v2.0-beta.12016-12-31

v2.2.0 → v3.0.02019-11-11

v3.4.x-dev → v4.0-beta.12022-04-19

v4.x-dev → v5.0.0-beta.12025-06-24

### Community

Maintainers

![](https://www.gravatar.com/avatar/ebb668d7515d81741c86e42cf3194f5623636fbb15dd5412e26ea8320865d229?d=identicon)[lagdo](/maintainers/lagdo)

---

Top Contributors

[![feuzeu](https://avatars.githubusercontent.com/u/15174329?v=4)](https://github.com/feuzeu "feuzeu (128 commits)")[![ITspirit](https://avatars.githubusercontent.com/u/2453696?v=4)](https://github.com/ITspirit "ITspirit (1 commits)")

---

Tags

phpsymfonyajaxJaxon

### Embed Badge

![Health badge](/badges/jaxon-php-jaxon-symfony/health.svg)

```
[![Health](https://phpackages.com/badges/jaxon-php-jaxon-symfony/health.svg)](https://phpackages.com/packages/jaxon-php-jaxon-symfony)
```

###  Alternatives

[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[dragon-code/support

Support package is a collection of helpers and tools for any project.

238.7M101](/packages/dragon-code-support)[lagdo/symfony-facades

Call Symfony services using facades.

1868.7k](/packages/lagdo-symfony-facades)[jaxon-php/jaxon-laravel

Jaxon library integration for the Laravel framework

101.8k4](/packages/jaxon-php-jaxon-laravel)[visithor/visithor-bundle

Visithor Bundle for Symfony

1620.2k3](/packages/visithor-visithor-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
