acad3b9457fa29bc2f8326deb827e919.json
1.57 KB
{"ast":null,"code":"/* eslint-disable react-hooks/rules-of-hooks */\nimport * as React from 'react';\nimport { isBrowserClient } from '../utils/commonUtil';\n/**\n * Wrap `React.useLayoutEffect` which will not throw warning message in test env\n */\n\nexport default function useLayoutEffect(effect, deps) {\n // Never happen in test env\n if (isBrowserClient) {\n /* istanbul ignore next */\n React.useLayoutEffect(effect, deps);\n } else {\n React.useEffect(effect, deps);\n }\n}\n/* eslint-enable */","map":{"version":3,"sources":["C:/Users/kkwan_000/Desktop/git/2017110269/minsung/node_modules/rc-select/es/hooks/useLayoutEffect.js"],"names":["React","isBrowserClient","useLayoutEffect","effect","deps","useEffect"],"mappings":"AAAA;AACA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,SAASC,eAAT,QAAgC,qBAAhC;AACA;AACA;AACA;;AAEA,eAAe,SAASC,eAAT,CAAyBC,MAAzB,EAAiCC,IAAjC,EAAuC;AACpD;AACA,MAAIH,eAAJ,EAAqB;AACnB;AACAD,IAAAA,KAAK,CAACE,eAAN,CAAsBC,MAAtB,EAA8BC,IAA9B;AACD,GAHD,MAGO;AACLJ,IAAAA,KAAK,CAACK,SAAN,CAAgBF,MAAhB,EAAwBC,IAAxB;AACD;AACF;AACD","sourcesContent":["/* eslint-disable react-hooks/rules-of-hooks */\nimport * as React from 'react';\nimport { isBrowserClient } from '../utils/commonUtil';\n/**\n * Wrap `React.useLayoutEffect` which will not throw warning message in test env\n */\n\nexport default function useLayoutEffect(effect, deps) {\n // Never happen in test env\n if (isBrowserClient) {\n /* istanbul ignore next */\n React.useLayoutEffect(effect, deps);\n } else {\n React.useEffect(effect, deps);\n }\n}\n/* eslint-enable */"]},"metadata":{},"sourceType":"module"}