
Research
Security News
Lazarus Strikes npm Again with New Wave of Malicious Packages
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
rollup-plugin-hbs
Advanced tools
Minimal handlebars template bundle rollup plugin based on rollup-plugin-handlebars-plus
Via Yarn
yarn add rollup-plugin-hbs --save-dev
Via NPM
npm install rollup-plugin-hbs --save-dev
// rollup.config.js
import hbs from 'rollup-plugin-hbs';
export default {
entry: 'entry.js',
dest: 'bundle.js',
plugins: [
hbs({
handlebars: {
// The module ID of the Handlebars runtime, exporting `Handlebars` as `default`.
// As a shortcut, you can pass this as the value of `handlebars` above.
// See the "Handlebars" section below.
id: 'handlebars', // Default: the path of Handlebars' CJS definition within this module
// Options to pass to Handlebars' `parse` and `precompile` methods.
options: {
// Whether to generate sourcemaps for the templates
sourceMap: true // Default: true
},
// Whether to remove newline and whitespace characters from compiled output.
optimize: true
},
// In case you want to compile files with other extensions.
templateExtension: '.html', // Default: '.hbs'
// A function that can determine whether or not a template is a partial.
isPartial: (name) => name.startsWith('_') // Default: as at left
})
]
}
{{! src/client/js/views/_messageBody.html }}
<p>{{message}}</p>
{{! src/client/js/views/message.html }}
<div>{{> _messageBody }}</div>
// main.js
import '_messageBody.html';
import MessageTemplate from 'message.html';
$('body').append(MessageTemplate({ message: 'Hello world!' }));
This software is licensed under the MIT License
FAQs
Handlebars template bundle rollup plugin
The npm package rollup-plugin-hbs receives a total of 200 weekly downloads. As such, rollup-plugin-hbs popularity was classified as not popular.
We found that rollup-plugin-hbs demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.
Security News
Opengrep continues building momentum with the alpha release of its Playground tool, demonstrating the project's rapid evolution just two months after its initial launch.