PHPackages                             camspiers/reactjs-php-render - 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. [Templating &amp; Views](/categories/templating)
4. /
5. camspiers/reactjs-php-render

ActiveLibrary[Templating &amp; Views](/categories/templating)

camspiers/reactjs-php-render
============================

React rendering from PHP

0.1.0(11y ago)458.0k41PHPPHP &gt;=5.4.0

Since Jul 20Pushed 9y ago7 watchersCompare

[ Source](https://github.com/camspiers/reactjs-php-render)[ Packagist](https://packagist.org/packages/camspiers/reactjs-php-render)[ RSS](/packages/camspiers-reactjs-php-render/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependencies (4)Versions (2)Used By (1)

ReactJS PHP Render
==================

[](#reactjs-php-render)

This library aims to provide multiple options for rendering React from PHP.

Experimental
------------

[](#experimental)

The API is experimental and is likely to change.

Concepts
--------

[](#concepts)

- Renderer (`ReactJS\Renderer\RendererInterface`)
- This interface is implemented by mutiple renderers to provide different potential rendering options (HTTP Server, V8Js etc)
- RuntimeFragmentProvider (`ReactJS\RuntimeFragmentProvider\ProviderInterface`)
- This interface is implemented to provider different environment support (CommonJS, Globals etc)

Usage
-----

[](#usage)

Renderers can be used directly to generate either "mountable" React HTML (including checksums and ids), or to generate static markup.

The React class (`ReactJS\React`) can be used to generate mountable React HTML along with JavaScript that will automatically mount the browser React component into the generated server rendered markup.

### Node

[](#node)

When using a node process, users are required to provide source file(s) in an appropriate format for node to execute, these source file(s) need include:

- React
- The component you are attempting to render

```
$node = ReactJS\ReactFactory::createUsingNode(
	'/usr/bin/nodejs',
	['bundle.js'] // bundle.js is a browserified bundle with React and TestComponent
);

echo $node->renderAutoMountingComponent('./TestComponent');
```

### V8

[](#v8)

When using the V8Js php extension, users are required to provide source file(s) in the appropriate format for V8 to execute, these source file(s) need include:

- React
- The component you are attempting to render

```
$v8 = ReactJS\ReactFactory::createUsingV8(
	['bundle.js'] // bundle.js is a browserified bundle with React and TestComponent
);

echo $v8->renderAutoMountingComponent('./TestComponent');
```

The result:

```

	Some testing content

	require('react').renderComponent(
		require(".\/TestComponent")(null),
		document.getElementById("53998c3f85044")
	)

```

Installation (with composer)
----------------------------

[](#installation-with-composer)

```
$ composer require camspiers/reactjs-php-render:dev-master

```

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity31

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 96.3% 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

Unknown

Total

1

Last Release

4320d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/91d02ba78b01d0432821f6195f11d6b95aa8da31f02f8aaea7a2e7215662061a?d=identicon)[camspiers](/maintainers/camspiers)

---

Top Contributors

[![camspiers](https://avatars.githubusercontent.com/u/51294?v=4)](https://github.com/camspiers "camspiers (26 commits)")[![pieterv](https://avatars.githubusercontent.com/u/438482?v=4)](https://github.com/pieterv "pieterv (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/camspiers-reactjs-php-render/health.svg)

```
[![Health](https://phpackages.com/badges/camspiers-reactjs-php-render/health.svg)](https://phpackages.com/packages/camspiers-reactjs-php-render)
```

###  Alternatives

[laravel/framework

The Laravel Framework.

34.7k509.9M17.0k](/packages/laravel-framework)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[magento/community-edition

Magento 2 (Open Source)

12.1k52.1k10](/packages/magento-community-edition)[craftcms/cms

Craft CMS

3.6k3.6M2.6k](/packages/craftcms-cms)[drupal/core

Drupal is an open source content management platform powering millions of websites and applications.

19562.3M1.3k](/packages/drupal-core)

PHPackages © 2026

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