
Security News
Axios Maintainer Confirms Social Engineering Attack Behind npm Compromise
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.
@ima/plugin-script-loader
Advanced tools
This is the plugin for loading 3rd party scripts for the IMA.js application. You can visit our site https://imajs.io.
npm install @ima/plugin-script-loader --save
// /app/build.js
var vendors = {
common: [
'@ima/plugin-script-loader'
]
};
/*
Now is script loader plugin available as:
import { ScriptLoaderPlugin, Events, defaultDependencies } from '@ima/plugin-script-loader';
*/
import Dispatcher from 'ima/event/Dispatcher';
import { ScriptLoader, Events as ScriptLoaderEvents, ScriptLoaderOptions } from '@ima/plugin-script-loader';
oc
.get(ScriptLoader)
.load('//www.example.com/script.js')
.then((result) => {
console.log('Script is loaded.', result.url);
})
.catch((error) => {
console.log('Script failed to load.', error);
});
oc
.get(Dispatcher)
.listen(ScriptLoaderEvents.LOADED, (result) => {
if (result.error) {
console.log('Script is not loaded.', result.url);
} else {
console.log('Script is loaded.', result.url);
}
});
import { ScriptLoader } from '@ima/plugin-script-loader';
// Load ES module with type="module"
oc
.get(ScriptLoader)
.load('//www.example.com/module.js', null, false, { module: true })
.then((result) => {
console.log('ES module is loaded.', result.url);
});
import { ScriptLoader } from '@ima/plugin-script-loader';
// Load script with custom attributes
oc
.get(ScriptLoader)
.load('//www.example.com/script.js', null, false, {
module: true, // Load as ES module
async: false, // Disable async loading
attributes: {
'crossorigin': 'anonymous',
'data-version': '1.0.0'
}
});
The load method accepts an optional options parameter of type ScriptLoaderOptions:
module?: boolean - Set to true to load the script as an ES module with type="module"async?: boolean - Set to false to disable async loading (default: true)attributes?: Record<string, string> - Custom attributes to set on the script elementFAQs
Seznam IMA.js plugin for loading script
We found that @ima/plugin-script-loader demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 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.

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.

Security News
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.