We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Tested on v6.1.4 after doing a large upgrade from v5.
<Switch checked={true} />
^ this gives a squiggly type error.
Check it out on your own StackBlitz link. Use the "controlled" switch example. https://mui.com/material-ui/react-switch/
Here's my forked version: https://stackblitz.com/edit/react-486rye?file=Demo.tsx
Type error
StackBlitz:
VSCodium:
No type error 👍
I'm writing code.
System: OS: Linux 6.6 NixOS 24.05 (Uakari) 24.05 (Uakari) Binaries: Node: 20.15.1 - /run/current-system/sw/bin/node npm: 10.7.0 - /run/current-system/sw/bin/npm pnpm: Not Found Browsers: Chrome: Not Found npmPackages: @emotion/react: ^11.13.3 => 11.13.3 @emotion/styled: ^11.13.0 => 11.13.0 @mui/base: 5.0.0-beta.59 @mui/core-downloads-tracker: 6.1.4 @mui/icons-material: ^6.1.4 => 6.1.4 @mui/lab: ^6.0.0-beta.12 => 6.0.0-beta.12 @mui/material: ^6.1.4 => 6.1.4 @mui/private-theming: 6.1.4 @mui/styled-engine: 6.1.4 @mui/system: 6.1.4 @mui/types: 7.2.18 @mui/utils: 6.1.4 @types/react: ^18.3.11 => 18.3.11 react: ^18.3.1 => 18.3.1 react-dom: ^18.3.1 => 18.3.1 typescript: ^5.6.3 => 5.6.3
{ "compilerOptions": { "target": "esnext", "lib": ["dom", "dom.iterable", "esnext"], "allowJs": true, "skipLibCheck": true, "strict": true, "noEmit": true, "esModuleInterop": true, "module": "esnext", "moduleResolution": "bundler", "resolveJsonModule": true, "isolatedModules": true, "jsx": "preserve", "incremental": true, "plugins": [ { "name": "next" } ], "paths": { "@/*": ["./src/*"] } }, "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], "exclude": ["node_modules"] }
Search keywords: Switch, checked, SwitchProps
The text was updated successfully, but these errors were encountered:
Alert is having similar typing issues:
Sorry, something went wrong.
Tested with v6.1.5 and it still seems to be an issue. For clarity I'm referring to both the switch component and the alert component.
Same error here, using the @mui/material/Radio component, using 5.15.19 Looks like this bug has been around for a while
I think this is a problem only in StackBlitz because it works for me locally.
mj12albert
No branches or pull requests
Steps to reproduce
Tested on v6.1.4 after doing a large upgrade from v5.
^ this gives a squiggly type error.
Check it out on your own StackBlitz link. Use the "controlled" switch example.
https://mui.com/material-ui/react-switch/
Here's my forked version:
https://stackblitz.com/edit/react-486rye?file=Demo.tsx
Current behavior
Type error
StackBlitz:
VSCodium:
Expected behavior
No type error 👍
Context
I'm writing code.
Your environment
Search keywords: Switch, checked, SwitchProps
The text was updated successfully, but these errors were encountered: