
Research
Supply Chain Attack on Axios Pulls Malicious Dependency from npm
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.
async-components-loader
Advanced tools
Dynamically load JavaScript modules from the DOM using data-component attributes.
📦 Dynamically load JavaScript modules based on data-component attributes in the DOM.
Each module must export a run() function that will be executed automatically.
npm install async-components-loader
<div data-component="Hello"></div>
<div data-component="World"></div>
Each component should export a run function:
// /components/Hello/index.ts
export function run() {
console.log("Hello component loaded!");
}
// /components/World/index.ts
export function run() {
console.log("World component loaded!");
}
import { init } from "async-components-loader";
init();
// 🔥 This will scan all elements with [data-component],
// dynamically import their modules and execute `run()`.
You can specify the base path where your components are located:
init("../custom-path/components");
By default, it looks for modules in ../components.
import { init } from "async-components-loader";
// Run all components declared in the DOM
document.addEventListener("DOMContentLoaded", () => {
init();
});
Clone the repo and build:
git clone https://github.com/Lauc1an/async-components-loader.git
cd async-components-loader
npm install
npm run build
Copyright © 2025 Alexander Pomareda
FAQs
Dynamically load JavaScript modules from the DOM using data-component attributes.
We found that async-components-loader demonstrated a healthy version release cadence and project activity because the last version was released less than 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
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.

Security News
TeamPCP is partnering with ransomware group Vect to turn open source supply chain attacks on tools like Trivy and LiteLLM into large-scale ransomware operations.