
Product
Introducing Socket Scanning for VS Code Marketplace Extensions
Socket now scans VS Code extensions, giving teams early detection of risky behaviors, hidden capabilities, and supply chain threats in developer tools.
To install this package:
npm install worp
If you use Typescript you don't need to download anything else. Typescript will be automatically loaded.
Javascript:
import { fixtureFactory } from "worp";
const factoryInstructions = {
a: index => `property A, record nr: ${index + 1}`,
b: index => index + 1,
c: () =>
`property C, random integer from 1 to 10: ${Math.ceil(Math.random() * 10)}`
};
const records = fixtureFactory(factoryInstructions, {
nrOfRecordsToGenerate: 100
});
Typescript:
import { fixtureFactory, FactoryInstructions } from "worp";
type ExampleProps = {
a: string;
b: number;
c: string;
};
const factoryInstructions: FactoryInstructions<ExampleProps> = {
a: index => `property A, record nr: ${index + 1}`,
b: index => index + 1,
c: () =>
`property C, random integer from 1 to 10: ${Math.ceil(Math.random() * 10)}`
};
const records = fixtureFactory(factoryInstructions, {
nrOfRecordsToGenerate: 100
});
This code will generate 100 objects like this:
[
{
a: "property A, record nr: 1",
b: 1,
c: "property C, random integer from 1 to 10: 3",
},
{
a: "property A, record nr: 2",
b: 2,
c: "property C, random integer from 1 to 10: 6",
},
... (98 more like this)
]
This package was created out of this boilerplate: https://github.com/michal-wrzosek/react-component-lib
FAQs
This package is useful when you need to quickly create lots of objects (fixtures) based on some instructions. Nice thing about this library is that it's super small (no dependencies) and it works very well with Typescript.
The npm package worp receives a total of 5 weekly downloads. As such, worp popularity was classified as not popular.
We found that worp 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.

Product
Socket now scans VS Code extensions, giving teams early detection of risky behaviors, hidden capabilities, and supply chain threats in developer tools.

Research
/Security News
Socket uncovered two malicious VS Code themes in a GlassWorm-linked cluster with thousands of installs across VS Code Marketplace and Open VSX.

Security News
/Company News
Capital One is partnering with Socket to proactively secure its open source supply chain.