0.2.0 • Published 5 years ago

metalsmith-drupal-attribute-twig v0.2.0

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

Metalsmith Plugin for Drupal Attributes NPM version

Build Status Dependency Status Greenkeeper badge

Metalsmith plugin to look for Drupal Attribute JSON maps to transform into Drupal Attribute objects for Twig

Installation

npm install --save metalsmith-drupal-attribute-twig

CLI

If you are using the command-line version of Metalsmith, you can install via npm, and then add the metalsmith-drupal-attribute-twig key to your metalsmith.json file:

{
  "plugins": {
    "metalsmith-drupal-attribute-twig": {
      inheritFilePrefix: '@kalastatic/'
    }
  }
}

JavaScript

If you are using the JS Api for Metalsmith, then you can require the module and add it to your .use() directives:

var jstransformer = require('metalsmith-drupal-attribute-twig');

metalsmith.use(jstransformer({
  'inheritFilePrefix': '@kalastatic/'
}));

License

MIT