
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
paperclip-component
Advanced tools
Paperclip-components allows you to break up your paperclip views into separate files, and re-use them in other parts of your application. This idea was derrived from Ember Components, and Angular Directives.
paperclip-compoenntnpm install paperclip-componentbower install paperclip-componentYou'll first need to add paperclip-component as a plugin:
var pc = require("paperclip"),
pcc = require("paperclip-component"),
bindable = require("bindable");
//where global components live.
var components = new bindable.Object();
//plugin paperclip-components, and point to the components dictionary
pc.use(pcc(components));
After you have that setup, you can start registering components. Here's one specific to a node.js application:
components.set("mainLayout", require("./mainLayout"));
mainLayout.js:
var mojo = require("mojojs"),
structr = require("structr"),
pc = require("paperclip")
var MainLayoutView = structr(mojo.View, {
paper: pc.load(__dirname + "/mainLayout.pc")
});
module.exports = MainLayoutView;
mainLayout.pc:
<html>
<head>
</head>
<body>
{{ html: sections.body }}
</body>
</html>
After you've defined your component, you can use it in any template. Here's how you might use mainLayout in a .pc file:
hello.pc:
{{#mainLayout}}
{{#sections: "body" }}
Hello World!
{{/}}
{{/}}
The rendered output of hello.pc would be:
<html>
<head>
</head>
<body>
Hello World!
</body>
</html>
FAQs
paperclip-view ==============
We found that paperclip-component 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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.