Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

metalsmith-layouts

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metalsmith-layouts - npm Package Compare versions

Comparing version 1.6.4 to 1.6.5

test/fixtures/partials-subdirectories/build/index.html

4

History.md

@@ -0,1 +1,5 @@

1.6.5 - May 3, 2016
-------------------
* normalize partial name for windows
1.6.4 - February 22, 2016

@@ -2,0 +6,0 @@ -------------------------

2

lib/helpers/read-partials.js

@@ -39,3 +39,3 @@ /**

partials[name] = partialPath;
partials[name.replace(/\\/g, '/')] = partialPath;
}

@@ -42,0 +42,0 @@

@@ -6,3 +6,3 @@ {

"repository": "git://github.com/superwolff/metalsmith-layouts.git",
"version": "1.6.4",
"version": "1.6.5",
"license": "MIT",

@@ -9,0 +9,0 @@ "main": "lib/index.js",

@@ -14,4 +14,6 @@ # metalsmith-layouts

This plugin allows you to apply layouts to your source files. It passes your source files to the selected layout as the variable `contents` and renders the result with the templating engine of your choice. You can use any templating engine supported by [consolidate.js](https://github.com/tj/consolidate.js#supported-template-engines). For support questions please use [stack overflow][stackoverflow-url] or our [slack channel][slack-url]. For templating engine specific questions try the aforementioned channels, as well as the documentation for [consolidate.js](https://github.com/tj/consolidate.js) and your templating engine of choice.
This plugin allows you to apply layouts to your source files. It passes your source files to the selected layout as the variable `contents` and renders the result with the templating engine of your choice. You can use any templating engine supported by [consolidate.js](https://github.com/tj/consolidate.js#supported-template-engines).
For support questions please use [stack overflow][stackoverflow-url] or our [slack channel][slack-url]. For templating engine specific questions try the aforementioned channels, as well as the documentation for [consolidate.js](https://github.com/tj/consolidate.js) and your templating engine of choice.
## Installation

@@ -18,0 +20,0 @@

@@ -125,2 +125,20 @@ var assert = require('assert');

it('should find partials in subdirectories correctly', function(done){
// This test would only fail on Windows if readPartials did not
// replace backslashes in partial names
var instance = Metalsmith('test/fixtures/partials-subdirectories')
.use(layouts({
engine: 'handlebars',
partials: 'layouts/partials'
}));
instance.build(function(err){
if (err) {
return done(err);
}
equal('test/fixtures/partials-subdirectories/expected', 'test/fixtures/partials-subdirectories/build');
done();
});
});
it('should accept a partials option', function(done){

@@ -127,0 +145,0 @@ Metalsmith('test/fixtures/partials-option')

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc