
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
anyfetch-handlebars
Advanced tools
Visit http://anyfetch.com for details about AnyFetch.
Inject new helpers in handlebars.
npm install
Check everything is working with npm test
.
var hbs = require('anyfetch-handlebars');
hbs.loadAnyfetchHelpers(/* Your context */);
var hbs = require('anyfetch-handlebars');
// An example of context
var rawDocument = {
data: {
text: 'Test of document'
},
metadata: {
path: '/test/document.txt'
},
highlight: {}
};
hbs.loadAnyfetchHelpers(rawDocument);
var compiled = hbs.compile("{ \
\"title\": \
{{#if metadata.title}} \
\"{{attr 'title'}}\" \
{{else}} \
{{#if metadata.path}} \
\"{{extractFilename metadata.path}}\" \
{{else}} \
\"Unknown document: no path.\" \
{{/if}} \
{{/if~}}, \
\"path\": \"{{attr 'path'}}\", \
\"snippet\": \"{{#trim .}}{{shortAttr 'text'}}{{/trim}}\" \
}");
var json = compiled(rawDocument);
// Beautify JSON
json = JSON.stringify(JSON.parse(json), null, 4);
This results in:
{
"title": "document",
"path": "/test/document.txt",
"snippet": "Test of document"
}
This repo is used extensively by AnyFetch. If your document-type needs a custom handlebars helper, you're welcome to fork. See Contributing for details.
master
Support: support@anyfetch.com
.
FAQs
> Visit http://anyfetch.com for details about AnyFetch.
The npm package anyfetch-handlebars receives a total of 2 weekly downloads. As such, anyfetch-handlebars popularity was classified as not popular.
We found that anyfetch-handlebars demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.