christophercliff / metalsmith-fingerprint

A fingerprint plugin for Metalsmith
MIT License
28 stars 7 forks source link

File are generated but no metadata #4

Closed ScottEAdams closed 9 years ago

ScottEAdams commented 9 years ago

Title says it all really. The files get generated correctly but I do not get any fingerprint metadata to use in hbars template.

christophercliff commented 9 years ago

The test is reporting otherwise: https://github.com/christophercliff/metalsmith-fingerprint/blob/master/test/index.js#L11

Please double check your implementation.

ScottEAdams commented 9 years ago

Strange, the tests also pass for me and if I add console.log(metalsmith.metadata()) in my build.js its printing the following:

{ title: 'Test',
  description: 'This is a test.',
  date: Wed Feb 18 2015 02:15:50 GMT+0100 (CET),
  fingerprint: { 'static/css/app.css': 'static/css/app-f5d9ccfe6f72ed3bfbac9580662a0bf3.css' } }

I can access title, description and date in my template but fingerprint is returning undefined.

christophercliff commented 9 years ago

I suspect your implementation is wrong. If you can post a failing test or runnable script that demonstrates the problem, please re-open.