Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: interpolate values #7

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

leviwheatcroft
Copy link

I've added interpolation of values so plugin calls can specify metadata values like { cover: 'images/{title}.jpg' }.

IDK if this is poor form, but I switched from minimatch to multimatch as it seems like that's become the defacto standard for metalsmith plugins. Doing that meant that it was sensible to fold the setmetadata fn back into the primary fn. So it looks like I've taken a knife to the original plugin but that wasn't really my intention.

Levi Wheatcroft added 3 commits January 22, 2017 17:19
 * update jshint & make .jshintrc more contemporary
 * breakout superfluous setmetadata fn
 * feature: interpolation
 * added interpolation test
@leviwheatcroft
Copy link
Author

Running "mochaTest:test" (mochaTest) task

>> Mocha exploded!

>> SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode

>>     at exports.runInThisContext (vm.js:53:16)

>>     at Module._compile (module.js:387:25)

>>     at Object.Module._extensions..js (module.js:422:10)

>>     at Module.load (module.js:357:32)

>>     at Function.Module._load (module.js:314:12)

>>     at Module.require (module.js:367:17)

>>     at require (internal/module.js:20:19)

>>     at Object.<anonymous> (/home/travis/build/dpobel/metalsmith-filemetadata/tests/file-metadata.js:3:10)

>>     at Module._compile (module.js:413:34)

>>     at Object.Module._extensions..js (module.js:422:10)

Warning: Task "mochaTest:test" failed.� Use --force to continue.

That sucked.. can we test against node 6 or do we need node 5 compat ?

@dpobel dpobel changed the base branch from master to main June 26, 2020 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant