Update Symfony packages to version 6.3

This commit is contained in:
Jeroen De Meerleer 2023-06-27 12:10:51 +02:00
parent fee87ef707
commit ea3814991d
Signed by: JeroenED
GPG Key ID: 28CCCB8F62BFADD6
11 changed files with 1244 additions and 659 deletions

View File

@ -8,14 +8,14 @@
"ext-ctype": "*",
"ext-iconv": "*",
"erusev/parsedown": "^1.7",
"symfony/console": "^6.2",
"symfony/dotenv": "^6.2",
"symfony/console": "^v6.3",
"symfony/dotenv": "^6.3",
"symfony/flex": "^2.2",
"symfony/framework-bundle": "^6.2",
"symfony/runtime": "^6.2",
"symfony/twig-bundle": "^6.2",
"symfony/webpack-encore-bundle": "^v1.16",
"symfony/yaml": "^6.2"
"symfony/framework-bundle": "^6.3",
"symfony/runtime": "^6.3",
"symfony/twig-bundle": "^6.3",
"symfony/webpack-encore-bundle": "^2.0",
"symfony/yaml": "^6.3"
},
"config": {
"allow-plugins": {

676
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -3,6 +3,7 @@ framework:
secret: '%env(APP_SECRET)%'
#csrf_protection: true
http_method_override: false
handle_all_throwables: true
# Enables session support. Note that the session will ONLY be started if you read or write from it.
# Remove or comment this section to explicitly disable session support.

View File

@ -25,14 +25,10 @@ webpack_encore:
# If you have multiple builds:
# builds:
# pass "frontend" as the 3rg arg to the Twig functions
# {{ encore_entry_script_tags('entry1', null, 'frontend') }}
# frontend: '%kernel.project_dir%/public/frontend/build'
# Cache the entrypoints.json (rebuild Symfony's cache when entrypoints.json changes)
# Put in config/packages/prod/webpack_encore.yaml
# cache: true
# pass the build name as the 3rd argument to the Twig functions
# {{ encore_entry_script_tags('entry1', null, 'frontend') }}
framework:
assets:

View File

@ -1,13 +1,5 @@
error:
path: '/error/{status}'
defaults:
_controller: App\Controller\DefaultController::ErrorAction
status: '404'
default:
path: '/{slug}'
defaults:
_controller: App\Controller\DefaultController::DefaultAction
slug: 'index'
requirements:
slug: "[a-zA-Z0-9\/]+"
controllers:
resource:
path: ../src/Controller/
namespace: App\Controller
type: attribute

1127
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -11,15 +11,22 @@
"js-cookie": "^3.0"
},
"devDependencies": {
"@symfony/webpack-encore": "^4.3",
"core-js": "^3.30",
"sass": "^1.62",
"sass-loader": "^13.2"
"@babel/core": "^7.17.0",
"@babel/preset-env": "^7.16.0",
"@symfony/webpack-encore": "^4.0.0",
"core-js": "^3.23.0",
"regenerator-runtime": "^0.13.9",
"webpack": "^5.74.0",
"webpack-cli": "^4.10.0",
"webpack-notifier": "^1.15.0"
},
"license": "UNLICENSED",
"private": true,
"scripts": {
"dev-server": "encore dev-server",
"dev": "encore dev",
"watch": "encore dev --watch",
"build-dev": "encore dev",
"build": "encore prod"
"build": "encore production --progress"
},
"repository": {
"type": "git",

View File

@ -7,9 +7,11 @@ use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
class DefaultController extends AbstractController
{
#[Route('/{slug}', name: 'default', requirements: ['slug' => '[a-zA-Z0-9\/]+'])]
public function DefaultAction(Request $request, Page $page, KernelInterface $kernel, string $slug = 'index')
{
$return = $page->getPage($kernel, $slug);
@ -17,7 +19,8 @@ class DefaultController extends AbstractController
return $this->render('/page.html.twig', $return, $response);
}
public function ErrorAction(Request $request, Page $page, KernelInterface $kernel, string $status)
#[Route('/error/{status}', name: 'error', requirements: ['status' => '[0-9]{3}'], priority: 2)]
public function ErrorAction(Request $request, Page $page, KernelInterface $kernel, string $status = '404')
{
$return = $page->getPage($kernel, 'error/' . $status);
$response = new Response('', (int)$status);

View File

@ -24,12 +24,12 @@
]
},
"symfony/framework-bundle": {
"version": "6.0",
"version": "6.3",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "main",
"version": "5.4",
"ref": "3cd216a4d007b78d8554d44a5b1c0a446dab24fb"
"version": "6.2",
"ref": "af47254c5e4cd543e6af3e4508298ffebbdaddd3"
},
"files": [
"config/packages/cache.yaml",
@ -43,12 +43,12 @@
]
},
"symfony/routing": {
"version": "6.0",
"version": "6.3",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "main",
"version": "6.0",
"ref": "eb3b377a4dc07006c4bdb2c773652cc9434f5246"
"version": "6.2",
"ref": "e0a11b4ccb8c9e70b574ff5ad3dfdcd41dec5aa6"
},
"files": [
"config/packages/routing.yaml",
@ -56,12 +56,12 @@
]
},
"symfony/twig-bundle": {
"version": "6.0",
"version": "6.3",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "main",
"version": "5.4",
"ref": "bb2178c57eee79e6be0b297aa96fc0c0def81387"
"version": "6.3",
"ref": "b7772eb20e92f3fb4d4fe756e7505b4ba2ca1a2c"
},
"files": [
"config/packages/twig.yaml",
@ -69,18 +69,15 @@
]
},
"symfony/webpack-encore-bundle": {
"version": "1.15",
"version": "2.0",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "main",
"version": "1.10",
"ref": "2e458cc7e6f1df1dad890eb104b81e4f302c9bd4"
"version": "2.0",
"ref": "13ebe04e25085e2ff0bcb0f9218b561d8b5089f3"
},
"files": [
"assets/app.js",
"assets/bootstrap.js",
"assets/controllers.json",
"assets/controllers/hello_controller.js",
"assets/styles/app.css",
"config/packages/webpack_encore.yaml",
"package.json",

View File

@ -1,4 +1,4 @@
<!doctype html>
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">

View File

@ -11,7 +11,7 @@ Encore
.setOutputPath('public/build/')
// public path used by the web server to access the output path
.setPublicPath('/build')
// only needed for CDN's or sub-directory deploy
// only needed for CDN's or subdirectory deploy
//.setManifestKeyPrefix('build/')
/*
@ -52,7 +52,7 @@ Encore
// enables @babel/preset-env polyfills
.configureBabelPresetEnv((config) => {
config.useBuiltIns = 'usage';
config.corejs = 3;
config.corejs = '3.23';
})
// enables Sass/SCSS support