Preserve file permissions on folder default

Hello,

Every time i log in on my site, permissions get changed to 550 on "docroot/sites/default". Can I prevent this?

The folder "default" must be writable for the owner in order for composer to work.

Owner of the directory "default" is an ordinary user without sudo rights. The group is the server. If the server is booth owner and group, it makes sense to chage to 550 but not if server already only has reading writes.

Fred

Difference between composer create-project drupal/recommended-project and composer create-project drupal-composer/drupal-project

Both install drupal 8.8.1

But /vendor folders are differents:

1) composer create-project drupal/recommended-project:

/vendor: 4485 files, ~21 Mo

2) composer create-project drupal-composer/drupal-project:

/vendor: 12624 files, ~62 Mo

What does it change? What does it mean? Which one is the best and why?

Twig Filter replace

I need replace field value to some text if value equal 0
in node--new_material.html.twig

{{ content.field_cena }} - it displays the value

These filter versions don't work

{{ content.field_cena|replace({'%0%': 'some text'}) }}
{{ content.field_cena|replace('0', 'some text') }}
{{ content.field_cena.0|replace({'%0%': 'some text'}) }}
{{ content.field_cena.0|replace('0', 'some text') }}

nothing is displayed.

Please tell me the solution!

How do I pass values from one twig to another?

I am getting all the values in node--blog--teaser.html.twig from a blog page.

Now i want to display in CARDS format in another page as a block. So i created another view with unformatted-list and tried overriding the views-view-unformatted.html.twig. 

But i am getting all the fields that i got in node twig like author_name, author_picture and other things.

I tried overriding the node.twig for unformatted-list with block type, but it was displaying the content from the blog page. 

Is it possible to extend the Drupal GraphQL module ?

Given a Website built on React fetching data from Drupal APIs exposed via the GraphQL module.
I have been asked to develop another area within the same website which requires data some Drupal plus some non-Drupal data.

My question is, "Which one of the following options is preferable?"

Option 1: Extending Drupal GraphQL to expose non-Drupal related data (Assuming the GraphQL module is extendable, not sure about that).

Option 2: Adding a new Custom GraphQL Layer and deal with Drupal as another source of data to be exposed.

Collapsible blocks

Hi,

I have a custom block and I want to make it collapsible sideways when it appears on my custom page. I have looked for examples but I found nothing helpful. Could you please guide me?

Thanks,

Pages

Subscribe with RSS Subscribe to RSS - Drupal 8.x