Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Dec 18, 2024
1 parent 90badf8 commit bfc7467
Show file tree
Hide file tree
Showing 2 changed files with 129 additions and 33 deletions.
78 changes: 63 additions & 15 deletions application/cs/@home.texy
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,7 @@ Nette Application
*****************

.[perex]
Balíček `nette/application` pΕ™edstavuje zΓ‘klad pro tvorbu interaktivnΓ­ch webovΓ½ch aplikacΓ­.

- [Jak fungujΓ­ aplikace? |how-it-works]
- [Bootstrap]
- [Presentery |presenters]
- [Ε ablony |templates]
- [Moduly |modules]
- [RoutovΓ‘nΓ­ |routing]
- [VytvΓ‘Ε™enΓ­ odkazΕ― URL |creating-links]
- [InteraktivnΓ­ komponenty |components]
- [AJAX & snippety |ajax]
- [Multiplier |multiplier]
- [Konfigurace |configuration]
Nette Application je jΓ‘drem frameworku Nette, kterΓ© pΕ™inΓ‘Ε‘Γ­ vΓ½konnΓ© nΓ‘stroje pro vytvΓ‘Ε™enΓ­ modernΓ­ch webovΓ½ch aplikacΓ­. NabΓ­zΓ­ Ε™adu vΓ½jimečnΓ½ch vlastnostΓ­, kterΓ© vΓ½raznΔ› usnadňujΓ­ vΓ½voj a zlepΕ‘ujΓ­ bezpečnost i udrΕΎovatelnost kΓ³du.


Instalace
Expand All @@ -26,10 +14,70 @@ Knihovnu stΓ‘hnete a nainstalujete pomocΓ­ nΓ‘stroje [Composer|best-practices:co
composer require nette/application
```


Proč zvolit Nette Application?
------------------------------

Nette bylo vΕΎdy prΕ―kopnΓ­kem v oblasti webovΓ½ch technologiΓ­.

**ObousmΔ›rnΓ½ router:** Nette disponuje pokročilΓ½m routovacΓ­m systΓ©mem, kterΓ½ je unikΓ‘tnΓ­ svou obousmΔ›rnostΓ­ - nejen ΕΎe pΕ™eklΓ‘dΓ‘ URL na akce aplikace, ale takΓ© dokΓ‘ΕΎe zpΔ›tnΔ› generovat URL adresy. To znamenΓ‘, ΕΎe:
- MΕ―ΕΎete kdykoliv zmΔ›nit strukturu URL celΓ© aplikace bez nutnosti upravovat Ε‘ablony
- URL jsou automaticky kanonizovΓ‘ny, coΕΎ zlepΕ‘uje SEO
- RoutovΓ‘nΓ­ je definovΓ‘no na jednom mΓ­stΔ›, nikoliv roztrouΕ‘enΔ› v anotacΓ­ch

**Komponenty a signΓ‘ly:** VestavΔ›nΓ½ komponentovΓ½ systΓ©m inspirovanΓ½ Delphi a React.js je mezi PHP frameworky zcela vΓ½jimečnΓ½:
- Umožňuje vytvΓ‘Ε™et znovupouΕΎitelnΓ© UI prvky
- Podporuje hierarchickΓ© sklΓ‘dΓ‘nΓ­ komponent
- NabΓ­zΓ­ elegantnΓ­ zpracovΓ‘nΓ­ AJAX poΕΎadavkΕ― pomocΓ­ signΓ‘lΕ―
- BohatΓ‘ knihovna hotovΓ½ch komponent na [Componette](https://componette.org)

**AJAX a snippety:** Nette pΕ™edstavilo revolučnΓ­ zpΕ―sob prΓ‘ce s AJAXem jiΕΎ v roce 2009, dlouho pΕ™ed podobnΓ½mi Ε™eΕ‘enΓ­mi jako Hotwire pro Ruby on Rails nebo Symfony UX Turbo:
- Snippety umožňují aktualizovat jen čÑsti strÑnky bez nutnosti psÑt JavaScript
- AutomatickΓ‘ integrace s komponentovΓ½m systΓ©mem
- ChytrÑ invalidace čÑstí strÑnek
- MinimΓ‘lnΓ­ mnoΕΎstvΓ­ pΕ™enΓ‘Ε‘enΓ½ch dat

**IntuitivnΓ­ Ε‘ablony [Latte|latte:]:** NejbezpečnΔ›jΕ‘Γ­ Ε‘ablonovacΓ­ systΓ©m pro PHP s pokročilΓ½mi funkcemi:
- AutomatickΓ‘ ochrana proti XSS s kontextovΔ› citlivΓ½m escapovΓ‘nΓ­m
- RozΕ‘iΕ™itelnost pomocΓ­ vlastnΓ­ch filtrΕ―, funkcΓ­ a značek
- DΔ›dičnost Ε‘ablon a snippety pro AJAX
- VynikajΓ­cΓ­ podpora PHP 8.x s typovΓ½m systΓ©mem

**Dependency Injection:** Nette plnΔ› vyuΕΎΓ­vΓ‘ Dependency Injection:
- AutomatickΓ© pΕ™edΓ‘vΓ‘nΓ­ zΓ‘vislostΓ­ (autowiring)
- Konfigurace pomocΓ­ pΕ™ehlednΓ©ho NEON formΓ‘tu
- Podpora pro tovΓ‘rny na komponenty


HlavnΓ­ vΓ½hody
-------------

- **Bezpečnost**: AutomatickÑ obrana proti zranitelnostem jako XSS, CSRF, atd.
- **Produktivita**: MΓ©nΔ› psanΓ­, vΓ­ce funkcΓ­ dΓ­ky chytrΓ©mu nΓ‘vrhu
- **Debugging**: [Tracy debugger|tracy:] s routovacΓ­m panelem
- **VΓ½kon**: ChytrΓ‘ cache, lazy loading komponent
- **Flexibilita**: SnadnÑ úprava URL i po dokončení aplikace
- **Komponenty**: UnikΓ‘tnΓ­ systΓ©m znovupouΕΎitelnΓ½ch UI prvkΕ―
- **ModernΓ­**: PlnΓ‘ podpora PHP 8.4+ a typovΓ©ho systΓ©mu


ZačínÑme
--------

1. [Jak fungujΓ­ aplikace? |how-it-works] - PochopenΓ­ zΓ‘kladnΓ­ architektury
2. [Presentery |presenters] - PrΓ‘ce s presentery a akcemi
3. [Ε ablony |templates] - Tvorba Ε‘ablon v Latte
4. [RoutovΓ‘nΓ­ |routing] - Konfigurace URL adres
5. [InteraktivnΓ­ komponenty |components] - VyuΕΎitΓ­ komponentovΓ©ho systΓ©mu


Kompatbility s PHP
------------------

| verze | kompatibilnΓ­ s PHP
|-----------|-------------------
| Nette Application 4.0 | PHP 8.1 – 8.3
| Nette Application 3.2 | PHP 8.1 – 8.3
| Nette Application 4.0 | PHP 8.1 – 8.4
| Nette Application 3.2 | PHP 8.1 – 8.4
| Nette Application 3.1 | PHP 7.2 – 8.3
| Nette Application 3.0 | PHP 7.1 – 8.0
| Nette Application 2.4 | PHP 5.6 – 8.0
Expand Down
84 changes: 66 additions & 18 deletions application/en/@home.texy
Original file line number Diff line number Diff line change
Expand Up @@ -2,36 +2,84 @@ Nette Application
*****************

.[perex]
The `nette/application` package is the basis for creating interactive web applications.

- [How do applications work? |how-it-works]
- [Bootstrap]
- [Presenters]
- [Templates]
- [Modules]
- [Routing]
- [Creating URL Links |creating-links]
- [Interactive Components |components]
- [AJAX & Snippets |ajax]
- [Multiplier |multiplier]
- [Configuration]
Nette Application is the core of the Nette framework that brings powerful tools for creating modern web applications. It offers numerous exceptional features that significantly simplify development and improve code security and maintainability.


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

Download and install the package using [Composer|best-practices:composer]:
Download and install the library using [Composer|best-practices:composer]:

```shell
composer require nette/application
```

| version | compatible with PHP

Why choose Nette Application?
-----------------------------

Nette has always been a pioneer in web technologies.

**Bidirectional Router:** Nette features an advanced routing system unique in its bidirectionality - it not only translates URLs to application actions but can also generate URLs in reverse. This means:
- You can modify the URL structure of the entire application at any time without modifying template files
- URLs are automatically canonicalized, improving SEO
- Routing is defined in one place, not scattered in annotations

**Components and Signals:** The built-in component system inspired by Delphi and React.js is unique among PHP frameworks:
- Enables creating reusable UI elements
- Supports hierarchical component composition
- Offers elegant AJAX request handling using signals
- Rich library of ready-made components on [Componette](https://componette.org)

**AJAX and Snippets:** Nette introduced a revolutionary way of working with AJAX in 2009, before solutions like Hotwire for Ruby on Rails or Symfony UX Turbo:
- Snippets allow updating only parts of the page without writing JavaScript
- Automatic integration with the component system
- Smart invalidation of page sections
- Minimal data transfer

**Intuitive [Latte|latte:] Templates:** The most secure templating system for PHP with advanced features:
- Automatic XSS protection with context-sensitive escaping
- Extensible with custom filters, functions, and tags
- Template inheritance and snippets for AJAX
- Excellent PHP 8.x support with type system

**Dependency Injection:** Nette fully utilizes Dependency Injection:
- Automatic dependency passing (autowiring)
- Configuration using clear NEON format
- Support for component factories


Main Benefits
-------------

- **Security**: Automatic protection against vulnerabilities like XSS, CSRF, etc.
- **Productivity**: Less writing, more features thanks to smart design
- **Debugging**: [Tracy debugger|tracy:] with routing panel
- **Performance**: Intelligent caching system, lazy loading of components
- **Flexibility**: Easy URL modification even after application completion
- **Components**: Unique system of reusable UI elements
- **Modern**: Full support for PHP 8.4+ and type system


Getting Started
---------------

1. [Understanding Applications |how-it-works] - Understanding basic architecture
2. [Presenters |presenters] - Working with presenters and actions
3. [Templates |templates] - Creating templates in Latte
4. [Routing |routing] - URL configuration
5. [Interactive Components |components] - Using the component system


PHP Compatibility
-----------------

| version | compatible with PHP
|-----------|-------------------
| Nette Application 4.0 | PHP 8.1 – 8.3
| Nette Application 3.2 | PHP 8.1 – 8.3
| Nette Application 4.0 | PHP 8.1 – 8.4
| Nette Application 3.2 | PHP 8.1 – 8.4
| Nette Application 3.1 | PHP 7.2 – 8.3
| Nette Application 3.0 | PHP 7.1 – 8.0
| Nette Application 2.4 | PHP 5.6 – 8.0

Applies to the latest patch versions.
Valid for the latest patch versions.

0 comments on commit bfc7467

Please sign in to comment.