@miyagi/twig-drupal

0.2.2 • Public • Published

@miyagi/twig-drupal

This extension adds support for specific twig and Drupal functionality to @miyagi/core.

Features

Drupal attributes

  • addClass
  • setAttribute

More about Drupal attributes

To use Drupal attributes in your mock files, add $drupal: true to the object.

twig

NOTE: If you need to add additional filters, functions or tags, please refer to the miyagi documentation.

Functions and filters

This plugin uses twig-drupal-filters, so all its functions and filters are supported.

Tags

  • trans / endtrans
  • plural

Installation

npm i --save-dev @miyagi/twig-drupal

or

yarn add -D @miyagi/twig-drupal

Usage

Add the extension to your .miyagi.js like this:

module.exports = {
  extensions: [require('@miyagi/twig-drupal')],
  ...
}

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.2.2
    530
    • latest

Version History

Package Sidebar

Install

npm i @miyagi/twig-drupal

Weekly Downloads

532

Version

0.2.2

License

MIT

Unpacked Size

13.3 kB

Total Files

7

Last publish

Collaborators

  • mgrsskls