
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
@infini-soft/hooks-draft
Advanced tools
Immutable Memento/Draft State React Hook. Using memento pattern, this tiny ~3k package adds up handy states to anything. You can change, undo, redo, draft, clear, commit, reset. Have status isDirty and if operation are available.
Immutable Memento/Draft State React Hook. Using memento pattern, this tiny ~3k package adds up handy states to anything. You can change, undo, redo, draft, clear, commit, reset. Have status isDirty and if operation are available.
Get all documentations, examples and execute it directly from our website, the ☕ kitchen! Come cook software :) https://www.kitchen.infini-soft.com/hooks/draft
$ npm install @infini-soft/hooks-draft --save
# or
$ yarn add @infini-soft/hooks-draft
import React from 'react';
import { useDraft } from '@infini-soft/hooks-draft'
export default () => {
const { data, draft, commit, clear, undo, redo, onChange, isDirty, reset } =
useDraft('I love Infini-soft :)');
return (
<div className="root">
<h1>Draft Example</h1>
<div>Dirty = {String(isDirty)}</div>
<div>Data = {data}</div>
<div>Draft = {draft}</div>
<input
type="text"
placeholder="change me..."
onChange={(e) => onChange(e.target.value)}
value={draft}
/>
<button onClick={commit.run} disabled={commit.disabled}>
Commit
</button>
<button onClick={clear.run} disabled={clear.disabled}>
Clear
</button>
<button onClick={reset.run} disabled={reset.disabled}>
Reset
</button>
<button onClick={undo.run} disabled={undo.disabled}>
Undo
</button>
<button onClick={redo.run} disabled={redo.disabled}>
Redo
</button>
</div>
);
};
Powered 🚀 by Infinisoft Inc.
Wanna cook the future? Come in the kitchen [https://www.kitchen.infini-soft.com]
FAQs
Immutable Memento/Draft State React Hook. Using memento pattern, this tiny ~3k package adds up handy states to anything. You can change, undo, redo, draft, clear, commit, reset. Have status isDirty and if operation are available.
We found that @infini-soft/hooks-draft demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 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
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

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.