Security News
NVD Backlog Tops 20,000 CVEs Awaiting Analysis as NIST Prepares System Updates
NVD’s backlog surpasses 20,000 CVEs as analysis slows and NIST announces new system updates to address ongoing delays.
@fluidframework/counter
Advanced tools
A SharedCounter
is a shared object which holds a number that can be incremented or decremented.
To create a SharedCounter
, get the factory and call create with a runtime and string ID:
const factory = SharedCounter.getFactory();
const counter = factory.create(this.runtime, id) as SharedCounter;
Once created, you can call increment
to modify the value with either a positive or negative number:
counter.increment(10); // add 10 to the counter value
counter.increment(-5); // subtract 5 from the counter value
To observe changes to the value (including those from remote clients), register for the "incremented"
event:
counter.on("incremented", (incrementAmount, newValue) => {
console.log(`The counter incremented by ${incrementAmount} and now has a value of ${newValue}`);
});
FAQs
Counter DDS
We found that @fluidframework/counter 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
NVD’s backlog surpasses 20,000 CVEs as analysis slows and NIST announces new system updates to address ongoing delays.
Security News
Research
A malicious npm package disguised as a WhatsApp client is exploiting authentication flows with a remote kill switch to exfiltrate data and destroy files.
Security News
PyPI now supports digital attestations, enhancing security and trust by allowing package maintainers to verify the authenticity of Python packages.