Ant-design: TS2304: 'PropertyKey' ์ด๋ฆ„์„ ์ฐพ์„ ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.

์— ๋งŒ๋“  2017๋…„ 07์›” 18์ผ  ยท  3์ฝ”๋ฉ˜ํŠธ  ยท  ์ถœ์ฒ˜: ant-design/ant-design

๋ฒ„์ „

2.12.1

ํ™˜๊ฒฝ

๋งฅOS 10.12.3

์žฌ์ƒ์‚ฐ ๋งํฌ

https://github.com/tylerlong/react-antd-ts-test

์žฌํ˜„ ๋‹จ๊ณ„

์ž์‹ ํด๋ก  https://github.com/tylerlong/react-antd-ts-test

์›์‚ฌ ์„ค์น˜

์›์‚ฌ ๋นŒ๋“œ

๋ฌด์—‡์„ ๊ธฐ๋Œ€ํ•ฉ๋‹ˆ๊นŒ?

๋ฌธ์ œ ์—†์ด ๋นŒ๋“œ๋˜์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

์‹ค์ œ๋กœ ๋ฌด์Šจ ์ผ์ด ์ผ์–ด๋‚˜๊ณ  ์žˆ์Šต๋‹ˆ๊นŒ?

โžœ ts-test git:(๋งˆ์Šคํ„ฐ) โœ— ์–€ ๋นŒ๋“œ
์›์‚ฌ ๋นŒ๋“œ v0.22.0
$ ์›นํŒฉ

[at-loader] typescript ์˜ [email protected] ๋ฐ /Users/tylerlong/src/react/ts-test/tsconfig.json์˜ "tsconfig.json" ์‚ฌ์šฉ.

[at-loader] ๋ณ„๋„์˜ ํ”„๋กœ์„ธ์Šค์—์„œ ๊ฒ€์‚ฌ ์‹œ์ž‘...

[at-loader] 2๊ฐœ์˜ ์˜ค๋ฅ˜๋กœ ํ™•์ธ์ด ์™„๋ฃŒ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.
ํ•ด์‹œ: c0b8bc6cbb418f703794
๋ฒ„์ „: ์›นํŒฉ 3.3.0
์‹œ๊ฐ„: 11342ms
์ž์‚ฐ ํฌ๊ธฐ ์ฒญํฌ ์ฒญํฌ ์ด๋ฆ„
bundle.js 3.67 MB 0 [๋ฐฉ์ถœ๋จ] [ํฐ] ๊ธฐ๋ณธ
bundle.js.map 3.83MB 0 [๋ฐฉ์ถœ๋จ] ๊ธฐ๋ณธ
[28] (webpack)/buildin/global.js 509๋ฐ”์ดํŠธ {0} [๋นŒ๋“œ๋จ]
[120] (webpack)/buildin/module.js 517๋ฐ”์ดํŠธ {0} [๋นŒ๋“œ๋จ]
[396] ./src/index.tsx 334๋ฐ”์ดํŠธ {0} [๋นŒ๋“œ๋จ]
[503] ./node_modules/moment/locale ^.\/.*$ 2.79kB {0} [์„ ํƒ ์‚ฌํ•ญ] [๋นŒ๋“œ๋จ]
[790] (webpack)/buildin/amd-options.js 82๋ฐ”์ดํŠธ {0} [๋นŒ๋“œ๋จ]
909 ์ˆจ๊ฒจ์ง„ ๋ชจ๋“ˆ

[at-loader] ./node_modules/antd/lib/table/Table.d.ts:109:27 ์˜ค๋ฅ˜
TS2304: 'PropertyKey' ์ด๋ฆ„์„ ์ฐพ์„ ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.

[at-loader] ./node_modules/antd/lib/table/Table.d.ts:112:33 ์˜ค๋ฅ˜
TS2304: 'PropertyKey' ์ด๋ฆ„์„ ์ฐพ์„ ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.
์˜ค๋ฅ˜ ๋ช…๋ น์ด ์ข…๋ฃŒ ์ฝ”๋“œ 2๋กœ ์‹คํŒจํ–ˆ์Šต๋‹ˆ๋‹ค.


๋ฐ๋ชจ ํ”„๋กœ์ ํŠธ๋Š” https://www.typescriptlang.org/docs/handbook/react-&-webpack.html ์— ๋”ฐ๋ผ ์ƒ์„ฑ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

๊ทธ๋ฆฌ๊ณ  ํ”„๋กœ์ ํŠธ์— antd๋ฅผ ์ถ”๊ฐ€ํ•˜๋ ค๊ณ  ํ•  ๋•Œ ๋ฌธ์ œ๊ฐ€ ์žˆ์Šต๋‹ˆ๋‹ค.

๊ฐ€์žฅ ์œ ์šฉํ•œ ๋Œ“๊ธ€

๋•Œ๋ฌธ์— PropertyKey ์— es2015 ๋‹น์‹ ์ด ํฌํ•จ๋˜์–ด์•ผํ•˜๋ฏ€๋กœ, ๋„์„œ๊ด€ es2015 ์ถ”๊ฐ€, ํŽธ์ง‘์˜๋ฅผ lib ์—์„œ ์˜ต์…˜์„ tsconfig.json .

        "lib": [
            "es5",
            "dom",
            "dom.iterable",
            "es2015"
        ]

๋ชจ๋“  3 ๋Œ“๊ธ€

๋•Œ๋ฌธ์— PropertyKey ์— es2015 ๋‹น์‹ ์ด ํฌํ•จ๋˜์–ด์•ผํ•˜๋ฏ€๋กœ, ๋„์„œ๊ด€ es2015 ์ถ”๊ฐ€, ํŽธ์ง‘์˜๋ฅผ lib ์—์„œ ์˜ต์…˜์„ tsconfig.json .

        "lib": [
            "es5",
            "dom",
            "dom.iterable",
            "es2015"
        ]

ํšจ๊ณผ๊ฐ€์žˆ๋‹ค! ๊ฐ์‚ฌ ํ•ด์š”

๋‹ค์Œ์„ ์ถ”๊ฐ€ํ•˜๋ฉด ์ถฉ๋ถ„ํ•ฉ๋‹ˆ๋‹ค.

"lib": [
            "dom",
            "es2015"
        ],

๊ฐ™์€ ๋ฌธ์ œ๊ฐ€ ์žˆ์Šต๋‹ˆ๋‹ค.
๋ฒ„์ „ 2.13.0
์ถ”๊ฐ€ํ•œ ํ›„:
"lib": [ "dom", "es2015" ],
๋งŽ์€ ์˜ค๋ฅ˜๊ฐ€ ์žˆ์Šต๋‹ˆ๋‹ค.

์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(22,4): ์˜ค๋ฅ˜ TS2687: 'val'์˜ ๋ชจ๋“  ์„ ์–ธ
ue'๋Š” ๋™์ผํ•œ ์ˆ˜์‹์–ด๋ฅผ ๊ฐ€์ ธ์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(45,4): ์˜ค๋ฅ˜ TS2687: 'siz'์˜ ๋ชจ๋“  ์„ ์–ธ
e'๋Š” ๋™์ผํ•œ ์ˆ˜์‹์–ด๋ฅผ ๊ฐ€์ ธ์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(51,4): ์˜ค๋ฅ˜ TS2687: 'pro'์˜ ๋ชจ๋“  ์„ ์–ธ
totype'์€ ์ˆ˜์ •์ž๊ฐ€ ๋™์ผํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(65,4): ์˜ค๋ฅ˜ TS2687: 'siz์˜ ๋ชจ๋“  ์„ ์–ธ
e'๋Š” ๋™์ผํ•œ ์ˆ˜์‹์–ด๋ฅผ ๊ฐ€์ ธ์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(71,4): ์˜ค๋ฅ˜ TS2687: 'pro'์˜ ๋ชจ๋“  ์„ ์–ธ
totype'์€ ์ˆ˜์ •์ž๊ฐ€ ๋™์ผํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(76,10): ์˜ค๋ฅ˜ TS2428: 'We
akMap'์€ ๋™์ผํ•œ ์œ ํ˜• ๋งค๊ฐœ๋ณ€์ˆ˜๋ฅผ ๊ฐ€์ ธ์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(85,26): ์˜ค๋ฅ˜ TS2344: ์œ ํ˜• 'K'๊ฐ€ ์ถฉ์กฑ๋˜์ง€ ์•Š์Œ
์ œ์•ฝ ์กฐ๊ฑด '๊ฐ์ฒด'๋ฅผ ์ง€์ •ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(86,55): ์˜ค๋ฅ˜ TS2344: ์œ ํ˜• 'K'๊ฐ€ ๋งŒ์กฑํ•˜์ง€ ์•Š์Œ
์ œ์•ฝ ์กฐ๊ฑด '๊ฐ์ฒด'๋ฅผ ์ง€์ •ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(87,4): ์˜ค๋ฅ˜ TS2403: ํ›„์† ๋ณ€์ˆ˜ decl
arations๋Š” ๊ฐ™์€ ์œ ํ˜•์ด์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ๋ณ€์ˆ˜ 'prototype'์€ 'WeakMap ์œ ํ˜•์ด์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.', ํ•˜์ง€๋งŒ ์—ฌ๊ธฐ์—๋Š” 'WeakMap ny, any>' ์œ ํ˜•์ด
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(87,4): ์˜ค๋ฅ˜ TS2687: 'pro'์˜ ๋ชจ๋“  ์„ ์–ธ
totype'์€ ์ˆ˜์ •์ž๊ฐ€ ๋™์ผํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(102,4): ์˜ค๋ฅ˜ TS2403: ํ›„์† ๋ณ€์ˆ˜ dec
larations๋Š” ๊ฐ™์€ ์œ ํ˜•์ด์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ' ํ•˜์ง€๋งŒ ์—ฌ๊ธฐ์—๋Š” 'WeakSet' ์œ ํ˜•์ด ์žˆ์Šต๋‹ˆ๋‹ค.'
.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-collections\index.d.ts(102,4): ์˜ค๋ฅ˜ TS2687: 'pr'์˜ ๋ชจ๋“  ์„ ์–ธ
ototype'์€ ์ˆ˜์ •์ž๊ฐ€ ๋™์ผํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-promise\index.d.ts(10,14): ์˜ค๋ฅ˜ TS2300: ์ค‘๋ณต ์‹๋ณ„์ž 'Promi
์„ธ'.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\es6-promise\index.d.ts(41,18): ์˜ค๋ฅ˜ TS2300: ์ค‘๋ณต ์‹๋ณ„์ž 'Promi
์„ธ'.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\@types\lodash\index.d.ts(19448,14): ์˜ค๋ฅ˜ TS2428: 'WeakMap'์˜ ๋ชจ๋“  ์„ ์–ธ
๋™์ผํ•œ ์œ ํ˜• ๋งค๊ฐœ๋ณ€์ˆ˜๋ฅผ ๊ฐ€์ ธ์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\typescriptliblib.es2015.collection.d.ts(44,10): ์˜ค๋ฅ˜ TS2428: ๋ชจ๋“  ์„ ์–ธ
'WeakMap'์˜ s๋Š” ๋™์ผํ•œ ์œ ํ˜• ๋งค๊ฐœ๋ณ€์ˆ˜๋ฅผ ๊ฐ€์ ธ์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\typescriptliblib.es2015.iterable.d.ts(156,10): ์˜ค๋ฅ˜ TS2428: ๋ชจ๋“  ์„ ์–ธ
'WeakMap'์˜ ์œ ํ˜• ๋งค๊ฐœ๋ณ€์ˆ˜๋Š” ๋™์ผํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\typescriptliblib.es2015.iterable.d.ts(210,10): ์˜ค๋ฅ˜ TS2300: ์ค‘๋ณต ID
'์•ฝ์†'.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\typescriptliblib.es2015.promise.d.ts(222,12): ์˜ค๋ฅ˜ TS2300: ์ค‘๋ณต ID
์ฆ‰ '์•ฝ์†'.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\typescriptliblib.es2015.symbol.wellknown.d.ts(132,10): ์˜ค๋ฅ˜ TS2428: ๋ชจ๋“  decl
'WeakMap'์˜ ๋ฐฐ์—ด์€ ๋™์ผํ•œ ์œ ํ˜• ๋งค๊ฐœ๋ณ€์ˆ˜๋ฅผ ๊ฐ€์ ธ์•ผ ํ•ฉ๋‹ˆ๋‹ค.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\typescriptliblib.es2015.symbol.wellknown.d.ts(167,10): ์˜ค๋ฅ˜ TS2300: ๋ณต์ œ
e ์‹๋ณ„์ž '์•ฝ์†'.
[10:20:42] ์˜ค๋ฅ˜ - typescript - node_modules\typescriptliblib.es5.d.ts(1287,10): ์˜ค๋ฅ˜ TS2300: ์ค‘๋ณต ์‹๋ณ„์ž 'Promi'
์„ธ'.

์ด ํŽ˜์ด์ง€๊ฐ€ ๋„์›€์ด ๋˜์—ˆ๋‚˜์š”?
0 / 5 - 0 ๋“ฑ๊ธ‰