- c - 在位数组中找到第一个零
- linux - Unix 显示有关匹配两种模式之一的文件的信息
- 正则表达式替换多个文件
- linux - 隐藏来自 xtrace 的命令
我有一个 Angular app in Plunker这不再有效,因为我已经将我的应用程序升级为使用 Angular 6 和 rxjs 6。
这是我的 config.js
文件:
var angularVersion;
if(window.AngularVersionForThisPlunker === 'latest'){
angularVersion = ''; //picks up latest
}
else {
angularVersion = '@' + window.AngularVersionForThisPlunker;
}
System.config({
//use typescript for compilation
transpiler: 'typescript',
//typescript compiler options
typescriptOptions: {
emitDecoratorMetadata: true
},
paths: {
'npm:': 'https://unpkg.com/'
},
//map tells the System loader where to look for things
map: {
'ngx-duration-picker': 'https://unpkg.com/ngx-duration-picker@latest/bundles/ngx-duration-picker.umd.js',
'app': './src',
'@angular/core': 'npm:@angular/core'+ angularVersion + '/bundles/core.umd.js',
'@angular/common': 'npm:@angular/common' + angularVersion + '/bundles/common.umd.js',
'@angular/common/http': 'npm:@angular/common' + angularVersion + '/bundles/common-http.umd.js',
'@angular/compiler': 'npm:@angular/compiler' + angularVersion + '/bundles/compiler.umd.js',
'@angular/platform-browser': 'npm:@angular/platform-browser' + angularVersion + '/bundles/platform-browser.umd.js',
'@angular/platform-browser-dynamic': 'npm:@angular/platform-browser-dynamic' + angularVersion + '/bundles/platform-browser-dynamic.umd.js',
'@angular/http': 'npm:@angular/http' + angularVersion + '/bundles/http.umd.js',
'@angular/router': 'npm:@angular/router' + angularVersion +'/bundles/router.umd.js',
'@angular/forms': 'npm:@angular/forms' + angularVersion + '/bundles/forms.umd.js',
'@angular/animations': 'npm:@angular/animations' + angularVersion + '/bundles/animations.umd.js',
'@angular/platform-browser/animations': 'npm:@angular/platform-browser' + angularVersion + '/bundles/platform-browser-animations.umd.js',
'@angular/animations/browser': 'npm:@angular/animations' + angularVersion + '/bundles/animations-browser.umd.js',
'@angular/core/testing': 'npm:@angular/core' + angularVersion + '/bundles/core-testing.umd.js',
'@angular/common/testing': 'npm:@angular/common' + angularVersion + '/bundles/common-testing.umd.js',
'@angular/common/http/testing': 'npm:@angular/common' + angularVersion + '/bundles/common-http-testing.umd.js',
'@angular/compiler/testing': 'npm:@angular/compiler' + angularVersion + '/bundles/compiler-testing.umd.js',
'@angular/platform-browser/testing': 'npm:@angular/platform-browser' + angularVersion + '/bundles/platform-browser-testing.umd.js',
'@angular/platform-browser-dynamic/testing': 'npm:@angular/platform-browser-dynamic' + angularVersion + '/bundles/platform-browser-dynamic-testing.umd.js',
'@angular/http/testing': 'npm:@angular/http' + angularVersion + '/bundles/http-testing.umd.js',
'@angular/router/testing': 'npm:@angular/router' + angularVersion + '/bundles/router-testing.umd.js',
'tslib': 'npm:tslib@1.6.1',
'rxjs': 'npm:rxjs',
'typescript': 'npm:typescript@2.2.1/lib/typescript.js'
},
//packages defines our app package
packages: {
app: {
main: './main.ts',
defaultExtension: 'ts'
},
rxjs: {
defaultExtension: 'js'
}
}
});
现在我遇到了这些错误:
Failed to load resource: net::ERR_FILE_NOT_FOUND unpkg.com/rxjs@6.2.1/operators.js:1 GET https://unpkg.com/rxjs@6.2.1/operators.js 404 () zone.js:388 Error: (SystemJS) Error: XHR error (404) loading https://unpkg.com/rxjs/operators.js
at XMLHttpRequest.wrapFn (https://unpkg.com/zone.js@0.8.26/dist/zone.js:1188:39)
at ZoneDelegate.invokeTask (https://unpkg.com/zone.js@0.8.26/dist/zone.js:421:31)
at Zone.runTask (https://unpkg.com/zone.js@0.8.26/dist/zone.js:188:47)
at ZoneTask.invokeTask [as invoke] (https://unpkg.com/zone.js@0.8.26/dist/zone.js:496:34)
at invokeTask (https://unpkg.com/zone.js@0.8.26/dist/zone.js:1540:14)
at XMLHttpRequest.globalZoneAwareCallback (https://unpkg.com/zone.js@0.8.26/dist/zone.js:1566:17) Error loading https://unpkg.com/rxjs/operators.js as "rxjs/operators" from https://unpkg.com/@angular/core/bundles/core.umd.js ZoneDelegate.invoke @ zone.js:388 Zone.run @ zone.js:138 (anonymous) @ ... GET https://unpkg.com/internal@1.0.8/observable/ConnectableObservable 404 () unpkg.com/internal@1.0.8/observable/merge:1 GET https://unpkg.com/internal@1.0.8/observable/merge 404 () unpkg.com/internal@1.0.8/Observable:1 GET https://unpkg.com/internal@1.0.8/Observable 404 () unpkg.com/internal@1.0.8/operators/groupBy:1 GET https://unpkg.com/internal@1.0.8/operators/groupBy 404 () unpkg.com/internal@1.0.8/util/UnsubscriptionError:1 GET https://unpkg.com/internal@1.0.8/util/UnsubscriptionError 404 () unpkg.com/internal@1.0.8/util/EmptyError:1 GET https://unpkg.com/internal@1.0.8/util/EmptyError 404 () unpkg.com/internal@1.0.8/scheduler/VirtualTimeScheduler:1 GET https://unpkg.com/internal@1.0.8/scheduler/VirtualTimeScheduler 404 () unpkg.com/internal@1.0.8/observable/generate:1 GET https://unpkg.com/internal@1.0.8/observable/generate 404 () unpkg.com/internal@1.0.8/observable/of:1 GET https://unpkg.com/internal@1.0.8/observable/of 404 () unpkg.com/internal@1.0.8/observable/iif:1 GET https://unpkg.com/internal@1.0.8/observable/iif 404 () unpkg.com/internal@1.0.8/AsyncSubject:1 GET https://unpkg.com/internal@1.0.8/AsyncSubject 404 () unpkg.com/internal@1.0.8/Notification:1 GET https://unpkg.com/internal@1.0.8/Notification 404 () unpkg.com/internal@1.0.8/observable/bindNodeCallback:1 GET https://unpkg.com/internal@1.0.8/observable/bindNodeCallback 404 () unpkg.com/internal@1.0.8/observable/timer:1 GET https://unpkg.com/internal@1.0.8/observable/timer 404 () unpkg.com/internal@1.0.8/util/identity:1 GET https://unpkg.com/internal@1.0.8/util/identity 404 () unpkg.com/internal@1.0.8/ReplaySubject:1 GET https://unpkg.com/internal@1.0.8/ReplaySubject 404 () unpkg.com/internal@1.0.8/config:1 GET https://unpkg.com/internal@1.0.8/config 404 () unpkg.com/internal@1.0.8/scheduler/animationFrame:1 GET https://unpkg.com/internal@1.0.8/scheduler/animationFrame 404 () unpkg.com/internal@1.0.8/observable/onErrorResumeNext:1 GET https://unpkg.com/internal@1.0.8/observable/onErrorResumeNext 404 () unpkg.com/internal@1.0.8/symbol/observable:1 GET https://unpkg.com/internal@1.0.8/symbol/observable 404 () unpkg.com/internal@1.0.8/observable/defer:1 GET https://unpkg.com/internal@1.0.8/observable/defer 404 () unpkg.com/internal@1.0.8/scheduler/asap:1 GET https://unpkg.com/internal@1.0.8/scheduler/asap 404 () unpkg.com/internal@1.0.8/util/ArgumentOutOfRangeError:1 GET https://unpkg.com/internal@1.0.8/util/ArgumentOutOfRangeError 404 () unpkg.com/internal@1.0.8/Subject:1 GET https://unpkg.com/internal@1.0.8/Subject 404 () unpkg.com/internal@1.0.8/scheduler/async:1 GET https://unpkg.com/internal@1.0.8/scheduler/async 404 () unpkg.com/internal@1.0.8/Subscriber:1 GET https://unpkg.com/internal@1.0.8/Subscriber 404 () unpkg.com/internal@1.0.8/observable/bindCallback:1 GET https://unpkg.com/internal@1.0.8/observable/bindCallback 404 () unpkg.com/internal@1.0.8/util/isObservable:1 GET https://unpkg.com/internal@1.0.8/util/isObservable 404 () unpkg.com/internal@1.0.8/util/noop:1 GET https://unpkg.com/internal@1.0.8/util/noop 404 () unpkg.com/internal@1.0.8/BehaviorSubject:1 GET https://unpkg.com/internal@1.0.8/BehaviorSubject 404 () unpkg.com/internal@1.0.8/observable/pairs:1 GET https://unpkg.com/internal@1.0.8/observable/pairs 404 () unpkg.com/internal@1.0.8/observable/never:1 GET https://unpkg.com/internal@1.0.8/observable/never 404 () unpkg.com/internal@1.0.8/observable/zip:1 GET https://unpkg.com/internal@1.0.8/observable/zip 404 () unpkg.com/internal@1.0.8/observable/empty:1 GET https://unpkg.com/internal@1.0.8/observable/empty 404 () unpkg.com/internal@1.0.8/observable/using:1 GET https://unpkg.com/internal@1.0.8/observable/using 404 () unpkg.com/internal@1.0.8/util/TimeoutError:1 GET https://unpkg.com/internal@1.0.8/util/TimeoutError 404 () unpkg.com/internal@1.0.8/scheduler/queue:1 GET https://unpkg.com/internal@1.0.8/scheduler/queue 404 () unpkg.com/internal@1.0.8/observable/forkJoin:1 GET https://unpkg.com/internal@1.0.8/observable/forkJoin 404 () unpkg.com/internal@1.0.8/Scheduler:1 GET https://unpkg.com/internal@1.0.8/Scheduler 404 () unpkg.com/internal@1.0.8/Subscription:1 GET https://unpkg.com/internal@1.0.8/Subscription 404 () unpkg.com/internal@1.0.8/observable/fromEventPattern:1 GET https://unpkg.com/internal@1.0.8/observable/fromEventPattern 404 () unpkg.com/internal@1.0.8/observable/range:1 GET https://unpkg.com/internal@1.0.8/observable/range 404 () unpkg.com/internal@1.0.8/observable/from:1 GET https://unpkg.com/internal@1.0.8/observable/from 404 () unpkg.com/internal@1.0.8/observable/interval:1 GET https://unpkg.com/internal@1.0.8/observable/interval 404 () unpkg.com/internal@1.0.8/util/ObjectUnsubscribedError:1 GET https://unpkg.com/internal@1.0.8/util/ObjectUnsubscribedError 404 () unpkg.com/internal@1.0.8/observable/combineLatest:1 GET https://unpkg.com/internal@1.0.8/observable/combineLatest 404 () unpkg.com/internal@1.0.8/observable/concat:1 GET https://unpkg.com/internal@1.0.8/observable/concat 404 () unpkg.com/internal@1.0.8/util/pipe:1 GET https://unpkg.com/internal@1.0.8/util/pipe 404 () unpkg.com/internal@1.0.8/observable/race:1 GET https://unpkg.com/internal@1.0.8/observable/race 404 () unpkg.com/internal@1.0.8/observable/fromEvent:1 GET https://unpkg.com/internal@1.0.8/observable/fromEvent 404 () unpkg.com/internal@1.0.8/observable/throwError:1 GET https://unpkg.com/internal@1.0.8/observable/throwError 404 ()
最佳答案
我已经通过如下修改我的 config.js
解决了这个问题:
var angularVersion;
if(window.AngularVersionForThisPlunker === 'latest'){
angularVersion = ''; //picks up latest
}
else {
angularVersion = '@' + window.AngularVersionForThisPlunker;
}
System.config({
transpiler: 'ts',
typescriptOptions: {
emitDecoratorMetadata: true,
experimentalDecorators: true
},
meta: {
'typescript': {
"exports": "ts"
}
},
paths: {
'npm:': 'https://unpkg.com/'
},
map: {
app: "./src",
'ngx-duration-picker': 'https://unpkg.com/ngx-duration-picker@latest/bundles/ngx-duration-picker.umd.js',
'@angular/core': 'npm:@angular/core'+angularVersion+'/bundles/core.umd.js',
'@angular/common': 'npm:@angular/common'+angularVersion+'/bundles/common.umd.js',
'@angular/compiler': 'npm:@angular/compiler'+angularVersion+'/bundles/compiler.umd.js',
'@angular/platform-browser': 'npm:@angular/platform-browser'+angularVersion+'/bundles/platform-browser.umd.js',
'@angular/platform-browser-dynamic': 'npm:@angular/platform-browser-dynamic'+angularVersion+'/bundles/platform-browser-dynamic.umd.js',
'@angular/http': 'npm:@angular/http'+angularVersion+'/bundles/http.umd.js',
'@angular/router': 'npm:@angular/router'+angularVersion+'/bundles/router.umd.js',
'@angular/forms': 'npm:@angular/forms'+angularVersion+'/bundles/forms.umd.js',
'@angular/upgrade': 'npm:@angular/upgrade'+angularVersion+'/bundles/upgrade.umd.js',
'@angular/upgrade/static': 'npm:@angular/upgrade'+angularVersion+'/bundles/upgrade-static.umd.js',
// other libraries
'rxjs': 'npm:rxjs',
'ts': 'npm:plugin-typescript',
'typescript': 'npm:typescript'
},
//packages defines our app package
packages: {
app: {
main: './main.ts',
defaultExtension: 'ts'
},
rxjs: {
main: 'index.js',
defaultExtension: 'js'
},
"rxjs/operators": {
main: 'index.js',
defaultExtension: 'js'
}
}
});
关于angular - Plunker 在更新到 Angular 6 和 rxjs 6 后损坏,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51288263/
关闭。这个问题需要更多focused .它目前不接受答案。 想改进这个问题吗? 更新问题,使其只关注一个问题 editing this post . 关闭 8 年前。 Improve this qu
我目前正在尝试制作一个非常简单的应用程序,它会根据一天中的时间问候。我的代码是: open System let read() = Console.Read() let readLine() = Co
我已经运行Elasticsearch服务很长时间了,但是突然遇到了以下情况 由以下原因导致:org.elasticsearch.index.translog.TranslogCorruptedExce
我对执行以下操作的 php 重定向脚本有一个奇怪的问题: 在用户的浏览器中植入 Cookie,或者读取现有 Cookie(如果有)。 将用户重定向到另一个网址(重定向的网址是原始网址中的参数,例如 h
我正在使用 iText 7.0.0(Java 风格),似乎表格单元格 HorizontalAlignment 被忽略,因为 CENTER 和 RIGHT 都不起作用。你能重现这个吗? see th
简而言之: 我有一个可以从多个线程访问的计数器变量。尽管我已经实现了多线程读/写保护,但该变量似乎仍然以不一致的方式同时写入,导致计数器结果不正确。 深入杂草: 我使用的“for 循环”会在后台触发大
我有一个 REST 项目,在访问控制服务类中保存用户的ArrayList。一切都工作正常,直到 REST Web 服务突然抛出 java.util.NoSuchElementException。单步查
已关闭。此问题不符合Stack Overflow guidelines 。它目前不接受答案。 这个问题似乎不是关于 a specific programming problem, a software
当我刷新页面时,我无法显示 voteUp/Down,因为如果我执行 voteUp/Down(+1 或 -1) 并刷新页面,这会再次返回 voteUp/Down (0)。过去我使用 JSON,但社区推荐
我正在为离散时间 CPU 调度模拟器编写代码。它只是生成流程并相应地安排它们。我目前正在实现 FCFS 计划。我理解离散时间模拟器的本质,但我在用 C++ 实现时遇到了麻烦。 问题出现在handleN
尝试使用 yum 部署包时出现错误: 2016-07-07 14:14:31,296 - ERROR - error: rpmdb: BDB0113 Thread/process 6723/1
我有一个简单的同步队列 template class SynchronisedQueue { public: void Enqueue(const T& d
我正在使用 hadoop 0.20.append 和 hbase 0.90.0。我将少量数据上传到 Hbase,然后出于评估目的杀死了 HMaster 和 Namenode。在此之后,我向 Hbase
我使用 symfony 框架 1.4 创建了一个网站。我正在使用 sfguard 进行身份验证。 现在,这在 WAMP (windows) 上运行良好。我可以在不同的浏览器上登录多个帐户并使用该网站。
目前我已经实现了 HashMap private static Map cached = new HashMap(); 和 Item 是一个具有属性的对象 Date expireTime 和 byte
我试图将 2 个不同的 WPF 控件绑定(bind)到 ViewModel 中的同一属性,即 CheckBox.IsChecked 和 Expander.IsExpanded。我想要实现的行为是让 C
我希望这是一个简单的问题,但我没有找到答案。 我想让 build.gradle 文件通过替换某些变量来设置我的 Spring Boot 应用程序中的版本。这与广告一样有效: def tokens =
已关闭。此问题需要 debugging details 。目前不接受答案。 编辑问题以包含 desired behavior, a specific problem or error, and the
这个问题在这里已经有了答案: In a fragment shader, why can't I use a flat input integer to index a uniform array o
我已经下载了 OSM 世界地图。解析时出现异常: osm bound changeset (...) changeset Exception in thread "main" org.xml.sax.
我是一名优秀的程序员,十分优秀!