Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf43c728

Browse files
authored
fix: VS code will now properly import operators, et al (#6276)
- Adds typesVersions, enforcing TypeScript >= 4.2.- Adds some superfluous references required for TS and VS Code to find proper import locations for our strange deep import sites.- Independantly tested by building the package and installing it locally in another project, then testing in VS code.Fixes#6067Relatedmicrosoft/TypeScript#43034
1 parente572d2e commitf43c728

File tree

2 files changed

+21
-1
lines changed

2 files changed

+21
-1
lines changed

‎package.json‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,12 @@
55
"main":"./dist/cjs/index.js",
66
"module":"./dist/esm5/index.js",
77
"es2015":"./dist/esm/index.js",
8-
"types":"./dist/types/index.d.ts",
8+
"types":"index.d.ts",
9+
"typesVersions": {
10+
">=4.2": {
11+
"*": ["dist/types/*"]
12+
}
13+
},
914
"sideEffects":false,
1015
"exports": {
1116
".": {

‎src/index.ts‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,18 @@
1+
//////////////////////////////////////////////////////////
2+
// Here we need to reference our other deep imports
3+
// so VS code will figure out where they are
4+
// see conversation here:
5+
// https://github.com/microsoft/TypeScript/issues/43034
6+
//////////////////////////////////////////////////////////
7+
8+
// tslint:disable: no-reference
9+
/// <reference path="./ajax/index.ts" />
10+
/// <reference path="./fetch/index.ts" />
11+
/// <reference path="./operators/index.ts" />
12+
/// <reference path="./testing/index.ts" />
13+
/// <reference path="./webSocket/index.ts" />
14+
// tslint:enable: no-reference
15+
116
/* Observable */
217
export{Observable}from'./internal/Observable';
318
export{ConnectableObservable}from'./internal/observable/ConnectableObservable';

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2026 Movatter.jp