Package Exports
- augmentor
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (augmentor) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
augmentor
React like hooks for the masses.
Available Hooks
- Basic Hooks
- Additional Hooks
- Third parts exported utilities
dropEffect(augmentedCallback)
executes any cleanup left from lastuseEffect(...)
invocation
example
You can test this example directly on Code Pen.
import {augmentor, useState} from 'augmentor';
// augment any function once
const a = augmentor(test);
a();
// ... or many times ...
const [b, c] = [test, test].map(augmentor);
b();
c();
function test() {
const [count, setCount] = useState(0);
// log current count value
console.log(count);
// will invoke this augmented function each second
setTimeout(() => setCount(count + 1), 1000);
}