segment-boneyard / metalsmith-templates

A metalsmith plugin to render files with templates.
46 stars 22 forks source link

Error: Uses a non existing method 'path' #45

Closed mxlv closed 9 years ago

mxlv commented 9 years ago

So I get this error message

...\node_modules\metalsmith-templates\lib\index.js:77
        str = metalsmith.path(dir, data.template || def);
                         ^
TypeError: Object #<Metalsmith> has no method 'path'
    at convert (...\node_modules\metalsmith-templates\lib\index.js:77:26)

I fixed it by changing line 77 to:

str = metalsmith.join(dir, data.template || def);

Anybody else has this issue?

ianstormtaylor commented 9 years ago

Hey thanks for this sorry for the delay. Now that https://github.com/superwolff has split out this plugin into two separate plugins—layouts and in-place—I'm going to deprecate the metalsmith-templates plugin, so that we can use the simpler ones instead. I'm going to close this issue, but feel free to re-open there!

Added a deprecation notice to the readme.