REST config ressource

Hello,

I needed to retreive the system.site page.front config value from js on front end (progressive decoupling)
I first thought of using  hook_page_attachments_alter() and inject the value in drupalSettings
But then i built a little module which provide any "simple config" through REST resource
I'll paste the rest resource plugin bellow but i have some questions :

How to convert drupal tokens in TWIG ?

{#
/**
 * @file
 * Default theme implementation for message entities.
 *
 * Available variables:
 * - $content: An array of comment items. Use render($content) to print them all, or
 *   print a subset such as render($content['field_example']). Use
 *   hide($content['field_example']) to temporarily suppress the printing of a
 *   given element.
 * - $title: The (sanitized) entity label.
 * - $url: Direct url of the current entity if specified.
 * - $page: Flag for the full page state.

Help required with SEO on Drupal 8

Hey there. I have a drupal 8 site that needs support improving the SEO of content... http://www.Openhandweb.org

Please check the site and offer some general views on how you would propose to proceed.

Looking for a long term engagement.

Best wishes

Chris

How to enable php extensions Array

I've installed drupal-8.7.2 & php 7.3.6 (Thread Safe).

In php.ini, I uncommented this line:

extension=pdo_sqlite

When I run this from the command prompt

php core/scripts/drupal quick-start demo_umami

I get this error:

ePosavje - News portal (Thunder distribution)

ePosavje - news portal (Paragraphs)

The ePosavje is a local, Slovenian news portal. It is build up based on Drupal 8 and Paragraphs module (Thunder distribution). 

It serves as a rich informational source for the latest news divided into classic categories (politics, sport, culture)...

Besides that, users can find information about food offers, city cameras, and posthumous information. 

Sectors: 
Media
Publishing

jQuery and drupal.behaviors in Drupal 8 : unable to run a function once

Hi,

I'm currently using some jQuery on my Drupal 8 website, but my function is running on every request and the lists generated by the script are duplicated. I tried to use .once() to avoid this problem, without success.

jQuery code running on every request :

(function($) {

Pages

Subscribe with RSS Subscribe to RSS - Drupal 8.x