腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
圈层
工具
MCP广场
文章/答案/技术大牛
搜索
搜索
关闭
发布
文章
问答
(9999+)
视频
沙龙
1
回答
类型
为
'(
e
:
MediaQueryListEvent
) =>
void
‘
的
参数
不能
赋值
给
类型
为
'(
e
:
Event
) =>
void
’
的
参数
reactjs
、
typescript
、
react-hooks
、
react-typescript
我创建了以下钩子来监听事件: const useEventListener = (
event
: keyof WindowEventMap, callback: (
e
:
Event
) =>
void
,element: EventTarget | null = window) => { const callbackRef = useRef<(
e
:
Event
) =>
void
>(callbackremoveEventListener(<e
浏览 143
提问于2021-11-11
得票数 0
1
回答
参数
类型
为
‘()?’
不能
赋值
给
参数
类型
'
void
()‘
flutter
、
dart
、
flutter-layout
我得到错误:
参数
类型
‘函数?’
不能
指定
参数
类型
'
void
(bool?)?‘。late bool _isFrontImageSelected;
void
initState() {
浏览 2
提问于2022-05-18
得票数 1
回答已采纳
2
回答
不能
将
类型
为
'() => =>‘
的
参数
赋值
给
类型
为
’()=>
void
‘
的
角度
参数
angular
Argument of type '(error: any) =>
void
'~~~~~~~~~ The last overlo
浏览 79
提问于2021-06-08
得票数 0
回答已采纳
1
回答
Promise:
类型
为
void
的
参数
不能
赋值
给
类型
T
node.js
、
promise
、
es6-promise
、
typescript2.0
我有一个类似上面的错误,但我找不到我
的
代码有任何错误。谁能告诉我正确
的
密码是什么? 谢谢
浏览 3
提问于2017-08-24
得票数 0
回答已采纳
2
回答
返回
类型
为
'TimerHandler‘
的
参数
的
Typescript
不能
赋值
给
类型
为
'
void
’
的
参数
?
javascript
、
angular
、
typescript
我想在angular 7中更新使用直播服务器收到
的
消息数量,就像我们在facebook和linkedin主页上一样,我已经尝试了以下代码:getMessageCount(rid:any
浏览 0
提问于2019-04-07
得票数 12
1
回答
“
void
”
类型
的
参数
不能
赋值
给
数组
类型
的
参数
angular
data.json() as Language[]; this.languageList=x; } 我已经创建了一个包含我
的
数据库fields.secondly
的
接口,我已经创建了一个服务,其中我已经创建了一个使用Http services.Now访问数据
的
函数,我想使用相同
的
创建函数来显示mat表中
的
数据。
浏览 1
提问于2018-03-19
得票数 0
1
回答
如何在addEventListener上解决打字符号中
的
错误
typescript
、
events
、
parameters
:boolean | AddEventListenerOptions | undefined):
void
',给出了以下错误。'(el: HTMLScriptElement,ev:
Event
) => any‘
类型
的
参数
不能
赋值
给
'(this: HTMLScriptElement,ev:
Event
) => any’
类型
的
参数
。:boolea
浏览 0
提问于2020-02-24
得票数 0
1
回答
使用SQLite
的
新Promise
的
类型
定义
typescript
、
react-native
、
sqlite
、
promise
、
react-typescript
我是Typescript
的
新手,我对Promise
的
类型
定义有问题。另外,我是第一次使用SQLite。Typescript建议我将
void
设置
为
resolve,但同时它指出on reject
void
在boolean
类型
上是不可
赋值
的
。:
类型
为
'(_:SQLTransaction,err: SQLError) SQLStatementErrorCallback‘
的
浏览 24
提问于2021-10-04
得票数 0
回答已采纳
1
回答
Flutter -函数
类型
的
参数
不能
赋值
给
` `
void
function()`
类型
的
参数
flutter
、
dart
我已经
为
ElevatedButton()创建了一个StatelessWidget,当我将一个selectHandler传递给ElevatedButton()
的
onPressed
参数
时,我得到了这个错误ElevatedButtonselectHandler是一个Function
类型
的
变量。 我哪里错了?
浏览 90
提问于2021-05-30
得票数 0
回答已采纳
6
回答
类型
'(
e
: CustomEvent) =>
void
‘
的
参数
不能
分配给'EventListenerOrEventListenerObject’
类型
的
参数
javascript
、
typescript
我有这个自定义事件设置,它适用于TypeScript 2.5.3,但是当我更新到2.6.1时,我会得到一个错误 // my code here
类型
'(
e
: CustomEvent) =>
void
‘
的
ts
参数
不能
分配给'EventListenerOrEventLis
浏览 18
提问于2017-11-07
得票数 40
回答已采纳
1
回答
如何在jest中模拟重载方法?
node.js
、
typescript
、
unit-testing
、
jestjs
: VerifyCallback,我
的
模块: const publicKeyToPem{ }我尝试在单元测试中模拟验证方法。jest.spyOn(jwt, 'verify').mockReturnValue(verifyResponse); }
浏览 18
提问于2020-05-12
得票数 4
1
回答
使用switchMap发出热
的
布尔值可观察值?
javascript
、
angular
、
typescript
、
rxjs
、
switchmap
正在尝试创建使用switchMap发出热Observable<boolean>
的
isEmpty:Observable<boolean>方法。)=>entries.length == 0));这个想法是,商店可以调用notifyOnEmpty.next(Object.values(this.entries)),让订阅者知道商店是否
为
空无论如何,switchMap语句会导致以下错误: '(entries:
E
[]) => boolean‘
类型
的
索引t<e
浏览 23
提问于2018-09-20
得票数 1
回答已采纳
1
回答
'any[]‘
类型
的
参数
不能
赋值
给
'(value:[any,Campaign[]]) =>
void
’
类型
的
参数
angular
、
typescript
、
rxjs
、
rxjs5
嗨,我在我
的
代码中收到一个打字错误。以下是我
的
代码。Argument of type 'any[]' is not assignable to parameter of type '(value: [any, Campaign[]]) =>
void
'Type 'any[]' provides no match for the signature '(value: [any, Campaign[]]):
void
'.ts(2345) Ca
浏览 23
提问于2019-04-16
得票数 1
1
回答
ngrx效果使
类型
“
void
”
不能
赋值
给
类型
“ObservableInput”
angular
、
rxjs
、
ngrx
、
ngrx-effects
、
ngrx-store
((response) => ))上面的代码给了我
类型
为
'(payload: any) =>
void
‘
的
参数
,但
不能
将其赋
给
类型
为
'(value: any,index: number) => ObservableInput’<e
浏览 1
提问于2017-06-15
得票数 3
回答已采纳
1
回答
编译Angular 2和Firebase存储时出错
angular
、
typescript
、
angular-cli
我目前使用
的
是Angular 4.x.x (所有最新版本)以及AngularFire和Firebase Storage。一切都很正常,直到对Angular CLI/编译器进行了更新,现在应用程序被渲染
为
无法编译。,我得到了一个错误,内容如下: '() =>
void
‘
类型
的
参数
不能
赋值
给
'Unsubscribe’
类型
的
参数
。
类型
浏览 8
提问于2017-08-04
得票数 2
回答已采纳
1
回答
无法在catcherror角度6中设置超时
angular
、
typescript
、
angular6
在catcherror中设置超时显示角度错误
不能
将(error: any) =>
void
类型
的
参数
赋值
给
(err: any, caught: Observable<HttpEvent<any>>)=> ObservableInput<{}>
类型
的
参数
。
类型
void
不能
赋值
给
<e
浏览 14
提问于2019-01-03
得票数 0
1
回答
在Angular 6中,'
void
‘
类型
的
参数
不能
赋值
给
'string’
类型
的
参数
angular
、
typescript
我
的
组件 this.details.=
event
.target.files[0]candidateDetails(){handleError (error: any) { } 错误:'
void
‘
类型
的
参数
不能</e
浏览 1
提问于2018-11-16
得票数 0
2
回答
类型
为
void
的
函数
参数
c++
、
c++17
是否可以在不定义GetValue<
void
>
的
显式专门化
的
情况下编译以下伪代码inline int GetValue(const Increment& inc = {}) if constexpr (std::is_same_v<Increment,
void
>) return 25;
浏览 0
提问于2020-03-08
得票数 2
2
回答
sa_handler :
不能
将"
void
“
类型
的
值
赋值
给
类型
为
"
void
(*)(int)”
的
实体
c
、
unix
我正在我
的
Mac上试用它,但它不起作用,正如我所知道
的
那样,这应该可以工作,但我不知道为什么。include <signal.h>#include <unistd.h>
void
fonction_fils() { fflush(stdout); }
浏览 5
提问于2022-03-14
得票数 -1
2
回答
为什么没有分配相同
的
闭包
类型
ios
、
swift
、
closures
、
variable-types
class ParentClass<T> var success : ((T)->
Void
)?} { { return self} 这里,我尝试将
参数
值
赋值
给
父类变量,但它
浏览 3
提问于2019-09-23
得票数 2
回答已采纳
点击加载更多
相关
资讯
C语言基础:通用指针
HarmonyOS4.0 TypeScript高级
java安全编码指南之:堆污染Heap pollution
Java学习笔记——异常处理
浅析:线程安全
热门
标签
更多标签
云服务器
ICP备案
对象存储
云点播
即时通信 IM
活动推荐
运营活动
广告
关闭
领券