小编ary*_*ngh的帖子

Firebase 函数部署抛出打字稿错误

我正在使用带有 Firebase 函数的打字稿。当我尝试使用npm run deploy内部函数目录进行部署时。它抛出太多打字稿错误。

../../../../node_modules/@types/react/index.d.ts:3208:13 - error TS2717: Subsequent property declarations must have the same type.  Property 'feFuncB' must be of type 'SVGProps<SVGFEFuncBElement>', but here has type 'SVGProps<SVGFEFuncBElement>'.

3208             feFuncB: React.SVGProps<SVGFEFuncBElement>;
                 ~~~~~~~

  ../node_modules/@types/react/index.d.ts:3108:13
    3108             feFuncB: React.SVGProps<SVGFEFuncBElement>;
                     ~~~~~~~
    'feFuncB' was also declared here.

../../../../node_modules/@types/react/index.d.ts:3209:13 - error TS2717: Subsequent property declarations must have the same type.  Property 'feFuncG' must be of type 'SVGProps<SVGFEFuncGElement>', but here has type 'SVGProps<SVGFEFuncGElement>'.

3209             feFuncG: React.SVGProps<SVGFEFuncGElement>;
                 ~~~~~~~

  ../node_modules/@types/react/index.d.ts:3109:13
    3109             feFuncG: React.SVGProps<SVGFEFuncGElement>;
                     ~~~~~~~
    'feFuncG' was …
Run Code Online (Sandbox Code Playgroud)

javascript firebase typescript google-cloud-functions

9
推荐指数
1
解决办法
1087
查看次数

useState 数组解构反应

我总是看到这种类型的代码:

const [value, setValue] = useState(null);
Run Code Online (Sandbox Code Playgroud)

既然value可以使用 进行更改setValue,为什么我们要使用constfor value

reactjs react-hooks

1
推荐指数
1
解决办法
199
查看次数