cleanup
This commit is contained in:
20
src/utils.js
20
src/utils.js
@@ -9,26 +9,6 @@ export const sqrt2 = Math.sqrt(2);
|
||||
// (2*S gives long width)
|
||||
export const sqrt3 = Math.sqrt(3);
|
||||
|
||||
//export function throttleEvent(type, name, obj) {
|
||||
// obj = obj || window;
|
||||
// let running = false;
|
||||
//
|
||||
// let throttle = () => {
|
||||
// if (!running) {
|
||||
// running = true;
|
||||
//
|
||||
// requestAnimationFrame(() => {
|
||||
// obj.dispatchEvent(new CustomEvent(name));
|
||||
// running = false;
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// obj.addEventListener(type, throttle);
|
||||
//}
|
||||
//
|
||||
//throttleEvent('resize', 'optimizedResize');
|
||||
|
||||
export function clone(obj) {
|
||||
return JSON.parse(JSON.stringify(obj));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user