-
Notifications
You must be signed in to change notification settings - Fork 132
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't expose global ResizeObserver #44
Comments
Alternatively, include the interface in the export~ |
weswigham
added a commit
to weswigham/resize-observer-polyfill
that referenced
this issue
Dec 4, 2018
Fixed in v1.5.1. |
Hello, I am still getting this type error with version Could this be a problem with my {
"compilerOptions": {
"target": "es5",
"lib": [
"dom",
"es5",
"es2015.promise",
"es2015.symbol",
"es2015.collection",
"esnext.array"
],
"allowJs": true,
"skipLibCheck": false,
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"strict": true,
"forceConsistentCasingInFileNames": true,
"module": "esnext",
"moduleResolution": "node",
"resolveJsonModule": true,
"isolatedModules": true,
"noEmit": true,
"jsx": "preserve"
},
"include": ["src"]
} EDIT: Sorry, false alarm. This was fixed when I upgraded to |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We've received bug reports that TypeScript complaints
Cannot find name 'ResizeObserver'.
#13405. Here is the code shows how we useResizeObserver
.I found that TypeScript removes the
import ResizeObserver from 'resize-observer-polyfill'
statement when generating declaration file. Here is the generated declaration file https://unpkg.com/antd@3.11.0/lib/input/TextArea.d.tsThe reason I guess is
ResizeObserver
was exposed as a global interface, not sure if it's a bug of TypeScript. But as #37 (comment) said, this library is actually a ponyfill, so there is no need to expose ResizeObserver as global right?The text was updated successfully, but these errors were encountered: