腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
圈层
工具
MCP广场
文章/答案/技术大牛
搜索
搜索
关闭
发布
文章
问答
(8110)
视频
沙龙
1
回答
Angular
2-
Injectable
()
装饰
器
、
、
我并不完全理解
Angular
2中的@
Injectable
装饰
器
,即使我不使用它,服务还是可以工作的。(请看下面的示例)使用@
Injectable
`export class AppService{ return "
浏览 5
提问于2017-01-23
得票数 2
回答已采纳
3
回答
不能解析APICalls的所有参数:(?)
这是我来自APICalls类的代码: }}来自app模块的代码:i
浏览 0
提问于2019-03-18
得票数 0
回答已采纳
1
回答
如何在
angular
6服务中发出Http请求
、
、
、
这是我的事情,我有一个消息服务,我想通过HTTP请求(Rest Api)从我的服务
器
收集数据,如下所示: this.mqttMessageData.push(data); });但是我的浏览
器
控制台上有这个错误/node_modules/@
angular
/compiler/fesm5/compiler.js.
浏览 13
提问于2018-08-22
得票数 3
回答已采纳
1
回答
解决路由
器
错误:未捕获错误:无法解析MemberListResolver的所有参数:
当我在
Angular
中创建Resolver时,我有一个问题。当我启动应用程序时,我给出了一个未捕获的错误:无法解析MemberListResolver的所有参数:(?)。错误。有人能帮我吗?我的Resolver类:export class MemberListResolver implements Resolve<Userprivate userService: UserService){} return this.userSe
浏览 3
提问于2020-04-06
得票数 0
1
回答
在提升角度的同时初始化类?
、
我有一个定制课程: private items = []; for(let i= 0; i < 5; i++) { } return this.items;}另一个自定义服务是: public co
浏览 0
提问于2019-06-28
得票数 1
回答已采纳
4
回答
既然我们可以在不使用
装饰
器
的情况下注入服务,为什么我们还要使用@
Injectable
()
装饰
器
呢?
、
、
、
我正在做一个项目,遇到了一个没有@
Injectable
()
装饰
器
的服务,它工作得很好。到目前为止,我的印象是,在
angular
中,如果我们想实现DI,我们必须使用@
injectable
()
装饰
器
并使用提供者对其进行配置。使用提供者配置服务是必需的,但使用@
injectable
()修饰
器
似乎不是。它只在一些服务中使用。在使用
装饰
器
的服务和不使用
装饰
器
的服务中,我注意
浏览 0
提问于2020-11-30
得票数 1
2
回答
在扩展验证
器
服务
angular
5中注入自定义服务
、
、
、
、
我正在扩展
angular
5的验证
器
服务。import { FormControl } from '@
angular
/forms';import {
Injectable
,Injector} from
浏览 17
提问于2018-01-04
得票数 0
1
回答
将存储注入errorhandler类
Angular
、
、
、
我正在尝试在我的应用程序中实现哨兵错误处理,现在我已经将其设置好并按预期工作。但现在我希望能够传递Sentry对象上的用户信息,以便更好地记录错误。export class SentryErrorHandler implements ErrorHandler { private _store: Store<AppState> this.getUserInfo(); this._store.s
浏览 0
提问于2020-03-11
得票数 1
1
回答
Angular
2从另一个服务调用服务
、
、
我在
angular
2中有两个服务- 1/Files和2/FTPClient。如下所示:因此,现在我想在FTPClient itself...so中使用文件服务
器
,
浏览 0
提问于2016-11-18
得票数 0
1
回答
每次创建服务-
Angular
、
、
、
、
import {
Injectable
} from '@
angular
/core'; providedIn: 'root'export class GlobalStateServiceAlertifyService, }import {BrowserModule} from '@
angular
浏览 2
提问于2020-11-08
得票数 0
2
回答
在
Angular
2 typescript中,@Inject和@
Injectable
有什么不同
、
、
、
我不知道什么时候使用@Inject,什么时候使用@
Injectable
?import {Component, Inject, provide} from '@
angular
/core'; import {Bun} from './bun'; @
Injecta
浏览 0
提问于2016-05-19
得票数 12
回答已采纳
1
回答
自动注册服务的角度
、
、
、
在Vue.js中,我使用require.context的技术,如中所记录的那样
浏览 2
提问于2020-10-12
得票数 0
回答已采纳
2
回答
C#属性修饰
器
的
Angular
7等效项
、
、
、
、
Authorize(ReadIndexes)]{} 有没有一种等效的方法来修饰一个方法来检查
Angular
浏览 18
提问于2019-06-20
得票数 2
回答已采纳
1
回答
角2.0 -注入的Http服务未定义
、
我添加了一个新的角2.0服务,我从角2.0组件中调用了这个服务:import {Inject} from '
angular
2/core';import {Http} from '
angular
2/http'; adapter.addProvid
浏览 1
提问于2015-12-24
得票数 11
回答已采纳
1
回答
提供的参数不匹配在类实例化时引发的调用目标错误的任何签名
、
、
、
homePage will be called instead of // module where all the paths and component are declaredim
浏览 2
提问于2017-12-27
得票数 0
回答已采纳
2
回答
角AOT和JIT在同一项目中的应用
、
、
、
、
在
angular
5上,我尝试在相同的项目上对我的大部分模块/组件进行AOT编译.但我有一个部分需要被JIT编辑。正如您将看到的,AOT编译从bundle中移除墙壁编译
器
,结果如下: Module not found: Error
浏览 1
提问于2018-03-13
得票数 9
回答已采纳
3
回答
在
Angular
DI中@Inject和
Injectable
的需求是什么?
、
、
但是为什么我们要在服务、管道和etc..Any上使用@Inject和
Injectable
呢?为什么以及我们需要在哪里使用它?import {
Injectable
} from '@
angular
/core'; export cla
浏览 2
提问于2017-08-17
得票数 0
1
回答
角: AngularJS $injector.invoke等价于调用可注入函数
、
使用特定的注入
器
($injector.invoke等效)调用此可注入函数?
浏览 0
提问于2019-06-16
得票数 0
回答已采纳
3
回答
如何在
angular
8中向扩展服务添加依赖项
、
、
local-storage.service.tsimport {DataEncryptionService} from/shared/data-encryption/data-encryption.service'; export class LocalStorageService {this.dataEncryptionService.encryptD
浏览 11
提问于2019-12-12
得票数 0
3
回答
类型“Observable<Response>”上不存在属性“”toPromise“”
、
、
、
import { Headers, Http } from '@
angular
/http'; export class PublisherService{ private
浏览 90
提问于2016-06-29
得票数 77
回答已采纳
点击加载更多
热门
标签
更多标签
云服务器
ICP备案
对象存储
云直播
实时音视频
活动推荐
运营活动
广告
关闭
领券