Sha256: 17ab406508937d3c16e8b3570cdd910e2c44ab1d2f72677f632b333996f225d2

Contents?: true

Size: 1.12 KB

Versions: 6

Compression:

Stored size: 1.12 KB

Contents

!function(n,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("preact")):"function"==typeof define&&define.amd?define(["exports","preact"],t):t(n.preactTestUtils={},n.preact)}(this,function(n,t){function e(){return t.options.t=t.options.debounceRendering,t.options.debounceRendering=function(n){return t.options.o=n},function(){return t.options.o&&t.options.o()}}var r=function(n){return null!=n&&"function"==typeof n.then},o=0;function i(){t.options.o&&(t.options.o(),delete t.options.o),void 0!==t.options.t?(t.options.debounceRendering=t.options.t,delete t.options.t):t.options.debounceRendering=void 0}n.setupRerender=e,n.act=function(n){if(++o>1){var f=n();return r(f)?f.then(function(){--o}):(--o,Promise.resolve())}var u,c,d=t.options.requestAnimationFrame,a=e();t.options.requestAnimationFrame=function(n){return u=n};var l,p,y=function(){try{for(a();u;)c=u,u=null,c(),a()}catch(n){l||(l=n)}finally{i()}t.options.requestAnimationFrame=d,--o};try{p=n()}catch(n){l=n}if(r(p))return p.then(y,function(n){throw y(),n});if(y(),l)throw l;return Promise.resolve()},n.teardown=i});
//# sourceMappingURL=testUtils.umd.js.map

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
isomorfeus-preact-10.9.0 node_modules/preact/test-utils/dist/testUtils.umd.js
isomorfeus-preact-10.8.2 node_modules/preact/test-utils/dist/testUtils.umd.js
isomorfeus-preact-10.8.1 node_modules/preact/test-utils/dist/testUtils.umd.js
isomorfeus-preact-10.8.0 node_modules/preact/test-utils/dist/testUtils.umd.js
isomorfeus-preact-10.7.3 node_modules/preact/test-utils/dist/testUtils.umd.js
isomorfeus-preact-10.7.2 node_modules/preact/test-utils/dist/testUtils.umd.js