Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Framework X Laravel Package

clue/framework-x

Framework X is a simple, fast micro framework for building reactive PHP web apps. Create routes, return PSR-7 responses, and run anywhere—behind a traditional web server or as a standalone server with ReactPHP under the hood.

View on GitHub
Deep Wiki
Context7

Framework X

CI status code coverage PHPStan level installs on Packagist

Framework X – the simple and fast micro framework for building reactive web applications that run anywhere.

Support us

We invest a lot of time developing, maintaining and updating our awesome open-source projects. You can help us sustain this high-quality of our work by becoming a sponsor on GitHub. Sponsors get numerous benefits in return, see our sponsoring page for details.

Let's take these projects to the next level together! 🚀

Quickstart

Start by creating an empty project directory. Next, we can start by taking a look at a simple example application. You can use this example to get started by creating a new public/ directory with an index.php file inside:

<?php

require __DIR__ . '/../vendor/autoload.php';

$app = new FrameworkX\App();

$app->get('/', function () {
    return React\Http\Message\Response::plaintext(
        "Hello wörld!\n"
    );
});

$app->get('/users/{name}', function (Psr\Http\Message\ServerRequestInterface $request) {
    return React\Http\Message\Response::plaintext(
        "Hello " . $request->getAttribute('name') . "!\n"
    );
});

$app->run();

Next, we need to install X and its dependencies to actually run this project. In your project directory, simply run the following command:

$ composer require clue/framework-x:^0.17

See also the CHANGELOG for details about version upgrades.

That's it already! The next step is now to serve this web application. One of the nice properties of this project is that is works both behind traditional web server setups as well as in a stand-alone environment.

For example, you can run the above example using the built-in web server like this:

$ php public/index.php

You can now use your favorite web browser or command line tool to check your web application responds as expected:

$ curl http://localhost:8080/
Hello wörld!

Documentation

Hooked? See website for full documentation.

Found a typo or want to contribute? The website documentation is built from the source documentation files in the docs/ folder.

Contribute

You want to contribute to the Framework X source code or documentation? You've come to the right place!

To contribute to the source code just locate the src/ folder and you'll find all content in there. Additionally, our tests/ folder contains all our unit tests and acceptance tests to assure our code works as expected. For more information on how to run the test suite check out our testing chapter.

If you want to contribute to the documentation of Framework X found on the website, take a look inside the docs/ folder. You'll find further instructions inside the README.md in there.

Found a typo on our website? Simply go to our website repository and follow the instructions found in the README.

Tests

To run the test suite, you first need to clone this repo and then install all dependencies through Composer:

$ composer install

To run the test suite, go to the project root and run:

$ vendor/bin/phpunit

The test suite is set up to always ensure 100% code coverage across all supported environments. If you have the Xdebug extension installed, you can also generate a code coverage report locally like this:

$ XDEBUG_MODE=coverage vendor/bin/phpunit --coverage-text

Additionally, you can run our sophisticated integration tests to verify the framework examples work as expected behind your web server. Use your web server of choice (see deployment documentation) and execute the tests with the URL to your installation like this:

$ php tests/integration/public/index.php
$ tests/integration.bash http://localhost:8080/

On top of this, we use PHPStan on max level to ensure type safety across the project:

$ vendor/bin/phpstan

License

This project is released under the permissive MIT license.

Did you know that I offer custom development services and issuing invoices for sponsorships of releases and for contributions? Contact me (@clue) for details.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky
spatie/mailcoach-vapor
spatie/laravel-javascript-views