Button
μ type
μμ±μ λν μ
λ ₯μ μ»€λ° μ΄ν @types/react
μ μ
λ ₯κ³Ό λ μ΄μ μΌμΉνμ§ μμ΅λλ€. https://github.com/DefinitelyTyped/DefinitelyTyped/commit/4d371be185ddd77264a8d7f30a7f7f8912738ed8
@ types / react : https://github.com/DefinitelyTyped/DefinitelyTyped/pull/34194 μ λ³κ²½μΌλ‘ μΈν΄ λ¬Έμ κ° λ°μνμ΅λλ€
v3.9.3μΌλ‘ μΆμλμμ΅λλ€.
@oliviertassinari tsconfig.json
μ paths
μ΅μ
μΌλ‘ μ¬λ°λ₯΄κ² μ¬μ μνλ λ°©λ²μ λν μκ° μμ΅λκΉ?
νμ¬ μν μ€ :
"paths": {
"@material-ui/core/*": ["typings/@material-ui/core/*"]
}
...
src/typings
βββ @material-ui
βββ core
βββ Button
βββ Button.d.ts
βββ Button.js
βββ index.d.ts
βββ index.js
νμ§λ§ λ΄κ° λκ° μλͺ»ν κ² κ°μ λλμ΄ λ€μ΄μ.
μ°λ¦¬λ @material-ui/core
μ μμ£Ό μ€λλ λ²μ μ μ¬μ©νκ³ μμ΅λλ€. κ·Έλ μ§ μμΌλ©΄ κ·Έλ₯ μ
κ·Έλ μ΄λνκ² μ΅λλ€.
κ°μ₯ μ μ©ν λκΈ
v3.9.3μΌλ‘ μΆμλμμ΅λλ€.