Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

DSFR libraries

Security covered Under active development 5 sites

Part of the Dsfr ecosystem · 12 projects

This module makes it easy to use components from the French State Design System (DSFR) in your Drupal project. It automatically registers DSFR components as Drupal libraries, allowing you to include their CSS and JavaScript in your pages.

This module automatically declares components from the French State Design System (DSFR) as Drupal libraries.

Features

If you need to use a component, you can attach it to your render array like this:

$build['#attached']['library'][] = 'dsfr_libraries/checkbox';

Or declare it as a dependency of your own library:

  dependencies:
    - dsfr_libraries/checkbox

The JS and CSS from this component will then be included in the page.

Additional Requirements

The dsfr needs to be installed in web/libraries/dsfr/.

For example, you can use Asset Packagist to install it with Composer:

{
    "require": {
        "npm-asset/gouvfr--dsfr": "^1.12"
    },
    "repositories": [
        {
            "type": "composer",
            "url": "https://asset-packagist.org"
        }
    ],
    "extra": {
        "installer-paths": {
            "web/libraries/dsfr": [
                "npm-asset/gouvfr--dsfr"
            ]
        },
        "installer-types": [
            "npm-asset"
        ]
    }
}

Ask your assistant about DSFR libraries

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
4
Tracked since
Oct 2024
Latest release
1 year ago
Releases (12 mo)
0 ▼ from 4
Maintenance
Dormant

Release Timeline

Releases

Version Type Core PHP Release date
1.0.0-alpha3 Pre-release 10–11 Nov 5, 2024
1.0.0-alpha2 Pre-release 10 Oct 30, 2024
1.0.0-alpha1 Pre-release 10 Oct 29, 2024
1.x-dev Dev 10–11 Oct 29, 2024