
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.
Programmatically include JavaScript and CSS files in the browser at runtime.
<html>
<head>
<script src="/path/to/include.js"></script>
<script>
include.once("/js/jquery.js", function () {
console.log('jquery is loaded');
});
include.css("/css/jquery-ui.css");
include(function () {
console.log('all includes are loaded');
});
</script>
</head>
<body>
Hello
</body>
</html>
Load a script referenced by path and call the optional callback function when it has been loaded.
If a string valued charset is passed as the second argument, then the charset attribute will be set
on the script element.
Call callback once all pending include files have been loaded.
Load a script referenced by path at most one time and call the optional callback function when it has been loaded.
If a string valued charset is passed as the second argument, then the charset attribute will be set
on the script element.
Callback is still called if the script has already been loaded one or more times.
path has been loaded.Load a stylesheet referenced by path.
pathAppend is a configuration option that is appended to each path.
If pathAppend is a function, it is called with path as its only argument. The return value should be a string to append to path.
Example using a string value:
var package = require('./package.json');
include.pathAppend = 'v=' + package.version;
Example using a function:
var package = require('./package.json');
include.pathAppend = function (path) {
if (~path.indexOf('mydomain.com')) {
return 'v=' + package.version;
}
else return '';
};
MIT
FAQs
Load js and css files programatically in the browser at run-time.
We found that jsinclude 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.