Skip to content

Update recipes 2022-11-28 #18

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

Conversation

symfony-php-recipes-bot
Copy link
Member

Q A
License MIT

The Symfony Recipes changed with version .
This PR contains the new definition for recipes.

@github-actions
Copy link

github-actions bot commented Nov 28, 2022

Thanks for the PR 😍

How to test these changes in your application

  1. Define the SYMFONY_ENDPOINT environment variable:

    # On Unix-like (BSD, Linux and macOS)
    export SYMFONY_ENDPOINT=https://raw.githubusercontent.com/schranz-php-recipes/symfony-recipes-php/flex/pull-18/index.json
    # On Windows
    SET SYMFONY_ENDPOINT=https://raw.githubusercontent.com/schranz-php-recipes/symfony-recipes-php/flex/pull-18/index.json
  2. Install the package(s) related to this recipe:

    composer req 'symfony/flex:^1.16'
    composer req 'symfony/ux-autocomplete:^2.6' 'symfony/ux-live-component:^2.6'
  3. Don't forget to unset the SYMFONY_ENDPOINT environment variable when done:

    # On Unix-like (BSD, Linux and macOS)
    unset SYMFONY_ENDPOINT
    # On Windows
    SET SYMFONY_ENDPOINT=

Diff between recipe versions

In order to help with the review stage, I'm in charge of computing the diff between the various versions of patched recipes.
I'm going keep this comment up to date with any updates of the attached patch.

symfony/ux-autocomplete

2.2 vs 2.6
diff --git a/symfony/ux-autocomplete/2.2/config/routes/ux_autocomplete.php b/symfony/ux-autocomplete/2.6/config/routes/ux_autocomplete.php
index 7a204db..b7a347f 100644
--- a/symfony/ux-autocomplete/2.2/config/routes/ux_autocomplete.php
+++ b/symfony/ux-autocomplete/2.6/config/routes/ux_autocomplete.php
@@ -5,6 +5,6 @@ declare(strict_types=1);
 use Symfony\Component\Routing\Loader\Configurator\RoutingConfigurator;
 
 return static function (RoutingConfigurator $routingConfigurator): void {
-    $routingConfigurator->import('@AutocompleteBundle/Resources/routes.php')
+    $routingConfigurator->import('@AutocompleteBundle/config/routes.php')
         ->prefix('/autocomplete');
 };

symfony/ux-live-component

2.0 vs 2.6
diff --git a/symfony/ux-live-component/2.0/config/routes/ux_live_component.php b/symfony/ux-live-component/2.6/config/routes/ux_live_component.php
index 51eff87..e7cb167 100644
--- a/symfony/ux-live-component/2.0/config/routes/ux_live_component.php
+++ b/symfony/ux-live-component/2.6/config/routes/ux_live_component.php
@@ -5,5 +5,6 @@ declare(strict_types=1);
 use Symfony\Component\Routing\Loader\Configurator\RoutingConfigurator;
 
 return static function (RoutingConfigurator $routingConfigurator): void {
-    $routingConfigurator->import('@LiveComponentBundle/Resources/config/routing/live_component.xml');
+    $routingConfigurator->import('@LiveComponentBundle/config/routes.php')
+        ->prefix('/_components');
 };

@alexander-schranz
Copy link
Member

Currently tests failing because some symfony ux components are not defining the requirements to the twig bundle correctly. See also: symfony/ux#569

@alexander-schranz
Copy link
Member

Tested manually the changes when the twig bundle is installed. All works like expected.

@alexander-schranz alexander-schranz merged commit 0d26fdd into schranz-php-recipes:main Nov 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants