Skip to content

Commit dd67164

Browse files
authored
Merge pull request #299 from knockout/revert/knip-and-module-resolution
Revert unapproved knip and moduleResolution PRs
2 parents b709f1a + dae7816 commit dd67164

64 files changed

Lines changed: 896 additions & 2131 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/dependency-cycle.yml

Lines changed: 0 additions & 32 deletions
This file was deleted.

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ coverage-temp
2424
builds/**/meta
2525
.nyc_output
2626
**/dist/*
27-
packages/**/types
28-
builds/reference/types
2927
!packages/tko/dist/*
3028

3129
*-debug.log
@@ -36,4 +34,3 @@ builds/reference/types
3634
.vscode/settings.json
3735
.playwright-mcp
3836
.playwright-cli
39-
.codex

Makefile

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,7 @@ package.json:
1818
node_modules: package-lock.json
1919

2020
all:: node_modules package-lock.json
21-
$(LERNA) --concurrency $(CONCURRENCY) exec --stream -- $(MAKE) && \
22-
$(MAKE) dts
21+
$(LERNA) --concurrency $(CONCURRENCY) exec --stream -- $(MAKE)
2322

2423
test:
2524
$(LERNA) exec --stream -- $(MAKE) test
@@ -52,27 +51,18 @@ format-fix:
5251
tsc:
5352
$(NPX) tsc
5453

55-
knip:
56-
$(NPX) knip --no-config-hints
57-
5854
eslint:
5955
$(NPX) eslint .
6056

6157
eslint-fix:
6258
$(NPX) eslint . --fix
6359

6460
dts:
65-
rm -rf .dts-tmp
66-
$(NPX) tsc --project tsconfig.dts.json --outDir .dts-tmp
67-
$(NODE) tools/sync-dts.mjs .dts-tmp packages,builds/reference
68-
rm -rf .dts-tmp
61+
$(NPX) tsc --build tsconfig.dts.json
6962

7063
docker-build:
7164
$(DOCKER) build . --tag tko
7265

73-
lerna-check:
74-
$(LERNA) exec --stream -- true
75-
7666
# Run the `repackage` target in every directory. Essentially
7767
# homogenizes the `package.json`.
7868
repackage: tools/repackage.mjs
@@ -107,7 +97,6 @@ sweep:
10797
rm -rf builds/*/dist/*
10898
rm -rf coverage/
10999
rm -rf coverage-temp/
110-
rm -rf packages/*/types/*
111100

112101
clean: sweep
113102
rm -rf node_modules/

builds/knockout/package.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@
2727
},
2828
"files": [
2929
"dist/",
30-
"helpers/",
31-
"types/"
30+
"helpers/"
3231
],
3332
"karma": {
3433
"frameworks": [
@@ -61,14 +60,14 @@
6160
"@tko/provider.multi": "^4.0.0",
6261
"@tko/provider.virtual": "^4.0.0",
6362
"@tko/utils.component": "^4.0.0",
64-
"@tko/utils.functionrewrite": "^4.0.0"
63+
"@tko/utils.functionrewrite": "^4.0.0",
64+
"tslib": "^2.2.0"
6565
},
6666
"exports": {
6767
".": {
68-
"types": "./types/index.d.ts",
6968
"require": "./dist/index.cjs",
7069
"import": "./dist/index.mjs"
7170
},
7271
"./helpers/*": "./helpers/*"
7372
}
74-
}
73+
}

builds/reference/package.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@
3030
"@tko/provider.native": "^4.0.0",
3131
"@tko/provider.virtual": "^4.0.0",
3232
"@tko/utils.component": "^4.0.0",
33-
"@tko/utils.jsx": "^4.0.0"
33+
"@tko/utils.jsx": "^4.0.0",
34+
"tslib": "^2.2.0"
3435
},
3536
"files": [
3637
"dist/",
37-
"helpers/",
38-
"types/"
38+
"helpers/"
3939
],
4040
"homepage": "https://tko.io",
4141
"licenses": [
@@ -46,7 +46,6 @@
4646
],
4747
"exports": {
4848
".": {
49-
"types": "./types/index.d.ts",
5049
"require": "./dist/index.cjs",
5150
"import": "./dist/index.mjs"
5251
},
@@ -55,4 +54,4 @@
5554
"bugs": {
5655
"url": "https://github.com/knockout/tko/issues"
5756
}
58-
}
57+
}

builds/reference/src/common.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
/**
22
* Without the following the only export is `default`
3-
*
43
*/
5-
// TODO remove? that is node or amd/umd stuff?
6-
//module.exports = require('./index').default
4+
module.exports = require('./index').default

eslint.config.js

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,30 @@
1-
const pluginJs = require('@eslint/js')
2-
const tseslint = require('typescript-eslint')
1+
import globals from "globals";
2+
import pluginJs from "@eslint/js";
3+
import tseslint from "typescript-eslint";
34

45

56
/** @type {import('eslint').Linter.Config[]} */
6-
module.exports = [
7+
export default [
78
pluginJs.configs.recommended,
89
...tseslint.configs.recommended,
9-
{ ignores: ['**/*.{js,mjs,cjs}', 'builds/**/*', '**/*.d.ts'] },
10+
{ ignores: ['**/*.{js,mjs,cjs}', 'builds/**/*'] },
1011
{
1112
rules: {
12-
'no-empty': 'off',
13-
'prefer-rest-params': 'off',
14-
'prefer-spread': 'off',
15-
'prefer-const': 'off',
16-
'no-useless-escape': 'off',
17-
'no-useless-assignment': 'off',
13+
"no-empty": "off",
14+
"prefer-rest-params" : "off",
15+
"prefer-spread": "off",
16+
"prefer-const": "off",
17+
"no-useless-escape": "off",
18+
"no-useless-assignment": "off",
1819
// "no-var": "off",
19-
'no-array-constructor': 'off',
20-
'no-misleading-character-class': 'off',
21-
'@typescript-eslint/no-this-alias': 'off',
22-
'@typescript-eslint/no-array-constructor': 'off',
23-
'@typescript-eslint/no-explicit-any': 'off',
24-
'@typescript-eslint/no-require-imports': 'off',
25-
'@typescript-eslint/no-unused-vars': 'off',
26-
'@typescript-eslint/no-unsafe-function-type': 'off'
20+
"no-array-constructor": "off",
21+
"no-misleading-character-class": "off",
22+
"@typescript-eslint/no-this-alias": "off",
23+
"@typescript-eslint/no-array-constructor": "off",
24+
"@typescript-eslint/no-explicit-any": "off",
25+
"@typescript-eslint/no-require-imports": "off",
26+
"@typescript-eslint/no-unused-vars" : "off",
27+
"@typescript-eslint/no-unsafe-function-type": "off"
2728
}
2829
}
29-
]
30+
];

knip.json

Lines changed: 0 additions & 21 deletions
This file was deleted.

0 commit comments

Comments
 (0)