Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor fixes #107

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 14 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,18 @@ $app = new FrameworkX\App();

$app->get('/', function () {
return new React\Http\Message\Response(
200,
[],
200, [
"Content-Type" => "text/plain; charset=UTF-8"
],
"Hello wörld!\n"
);
});

$app->get('/users/{name}', function (Psr\Http\Message\ServerRequestInterface $request) {
return new React\Http\Message\Response(
200,
[],
200, [
"Content-Type" => "text/plain; charset=UTF-8"
],
"Hello " . $request->getAttribute('name') . "!\n"
);
});
Expand All @@ -43,7 +45,14 @@ $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:
In your project directory, simply run the following commands:

```bash
$ composer init
```

This will create an empty `composer.json` file. Just press return a few times
to accept the default answers to any prompts when asked, and then run:

```bash
$ composer require clue/framework-x:dev-main
Expand Down