You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/Web/Documentation/content/main/0-getting-started/00-introduction.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,9 +5,9 @@ description: "Tempest is a PHP framework designed to get out of your way. Its co
5
5
6
6
Tempest makes writing PHP applications pleasant thanks to carefully crafted quality-of-life features that feel like a natural extension of vanilla PHP.
7
7
8
-
It embraces modern PHP syntax in its implementation of routing, ORM, console commands, messaging, logging, it takes inspiration from the best front-end frameworks for its templating engine syntax, and provides unique capabilities amongst other framework, such as [discovery](../3-internals/02-discovery), to improve developer experience.
8
+
It embraces modern PHP syntax in its implementation of routing, ORM, console commands, messaging, logging, it takes inspiration from the best front-end frameworks for its templating engine syntax, and provides unique capabilities, such as [discovery](../3-internals/02-discovery), to improve developer experience.
9
9
10
-
You may also be interested in reading how it has an [unfair advantage](/blog/unfair-advantage) over other frameworks. But code says more than words, so here are a few examples of code written on top of Tempest:
10
+
You may be interested in reading how it has an [unfair advantage](/blog/unfair-advantage) over other frameworks—but code says more than words, so here are a few examples of code written on top of Tempest:
11
11
12
12
```php
13
13
use Tempest\Router\Get;
@@ -87,6 +87,8 @@ This is a [console command](../2-console/02-building-console-commands). Console
87
87
88
88
This example also shows how to [register events globally](../1-framework/07-events) using the `#[EventHandler]`.
89
89
90
+
---
91
+
90
92
:::info Ready to give it a try?
91
93
Keep on reading and consider [**giving Tempest a star️ on GitHub**](https://github.com/tempestphp/tempest-framework). If you want to be part of the community, you can [**join our Discord server**](https://discord.gg/pPhpTGUMPQ), and if you feel like contributing, you can check out our [contributing guide](/docs/internals/contributing)!
Copy file name to clipboardExpand all lines: src/Web/Documentation/content/main/0-getting-started/01-getting-started.md
+18-18Lines changed: 18 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,23 +16,23 @@ Once the prerequisites are installed, you can chose your installation method. Te
16
16
To get started with a new Tempest project, you may use {`tempest/app`} as the starting point. The `composer create-project` command will scaffold it for you:
If you have a dedicated development environment, you may then access your application by opening `https://my-app.test` in your browser. Otherwise, you may use PHP's built-in server:
24
24
25
25
```sh
26
-
php tempest serve
27
-
#PHP 8.3.3 Development Server (http://localhost:8000) started
26
+
{:hl-keyword:php:} tempest serve
27
+
{:hl-comment:PHP 8.3.3 Development Server (http://localhost:8000) started:}
28
28
```
29
29
30
30
### Scaffolding front-end assets
31
31
32
32
Optionally, you may install a basic front-end scaffolding that includes [Vite](https://vite.dev/) and [Tailwind CSS](https://tailwindcss.com/). To do so, run the Vite installer and follow through the wizard:
33
33
34
34
```sh
35
-
php tempest install vite --tailwind
35
+
{:hl-keyword:php:} tempest install vite --tailwind
36
36
```
37
37
38
38
<!-- TODO: docs -->
@@ -41,21 +41,21 @@ The assets created by this wizard, `main.entrypoint.ts` and `main.entrypoint.css
41
41
You may then run the front-end development server, which will serve your assets on-the-fly:
42
42
43
43
```bash
44
-
npm run dev
44
+
{:hl-keyword:npm:} run dev
45
45
```
46
46
47
47
## Tempest as a package
48
48
49
49
If you already have a project, you can opt to install {`tempest/framework`} as a standalone package. You could do this in any project; it could already contain code, or it could be an empty project.
Installing Tempest this way will give you access to the Tempest console, `./vendor/bin/tempest`. Optionally, you can choose to install Tempest's entry points in your project. To do so, you may run the framework installer:
This installer will prompt you to install the following files into your project:
@@ -84,10 +84,10 @@ The following projects structures work the same way in Tempest, without requirin
84
84
```txt
85
85
app
86
86
├── Console
87
-
│ └── RssSyncCommand.php
87
+
│ └── RssSyncCommand.php
88
88
├── Controllers
89
-
│ ├── BlogPostController.php
90
-
│ └── HomeController.php
89
+
│ ├── BlogPostController.php
90
+
│ └── HomeController.php
91
91
└── Views
92
92
├── blog.view.php
93
93
└── home.view.php
@@ -96,9 +96,9 @@ app
96
96
```txt
97
97
src
98
98
├── Blog
99
-
│ ├── BlogPostController.php
100
-
│ ├── RssSyncCommand.php
101
-
│ └── blog.view.php
99
+
│ ├── BlogPostController.php
100
+
│ ├── RssSyncCommand.php
101
+
│ └── blog.view.php
102
102
└── Home
103
103
├── HomeController.php
104
104
└── home.view.php
@@ -174,12 +174,12 @@ By default, the discovery cache is disabled in local development. Depending on y
174
174
This caching strategy will only cache discovery for vendor files. For this reason, it is recommended to run `discovery:generate` after every composer update:
0 commit comments