Security News
Supply Chain Attack Detected in @solana/web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
@homer0/package-info
Advanced tools
A tiny service that reads the contents of the project's package.json
, sync & async.
⚠️ This package is only for Node.
import { packageInfo } from '@homer0/package-info';
const pkg = packageInfo();
// ...
const info = await pkg.get();
// or
const info = pkg.getSync();
If your app uses a Jimple container, you can register PackageInfo
as the packageInfo
service by using its provider:
import { packageInfoProvider } from '@homer0/package-info';
// ...
container.register(packageInfoProvider);
// ...
const info = container.get('packageInfo');
And since the provider is a "provider creator" (created with my custom version of Jimple), you can customize its service name:
container.register(
packageInfoProvider({
serviceName: 'myPackageInfo',
}),
);
PackageInfo
depends on the following services, and when used with Jimple, it will try to find them in the container, otherwise, it will create new instances:
@homer0/path-utils
, with the name pathUtils
. Used to generate the paths relative to the project root.If you already implement the dependencies, but with a different name, you can specify them in the provider:
container.register(
packageInfoProvider({
services: {
pathUtils: 'myPathUtils',
},
}),
);
As this project is part of the packages
monorepo, it requires Yarn, and some of the tooling, like ESLint and Husky, are installed on the root's package.json
.
Task | Description |
---|---|
test | Runs the unit tests. |
build | Bundles the project. |
FAQs
Gets the content of the project's package.json
The npm package @homer0/package-info receives a total of 15 weekly downloads. As such, @homer0/package-info popularity was classified as not popular.
We found that @homer0/package-info 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
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.