Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NODEJS-680: Update and Automate TypeScript Support #436

Open
wants to merge 21 commits into
base: typescript
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
a003557
tsconfig
SiyaoIsHiding Jan 16, 2025
8078d90
tests can run
SiyaoIsHiding Jan 21, 2025
9dc0a4c
can run tests and emit files
SiyaoIsHiding Jan 21, 2025
2628567
auth folder migrated to es6 export, tests break
SiyaoIsHiding Jan 21, 2025
5efc443
change test files to ts, can run by "npx ts-mocha test/unit --extensi…
SiyaoIsHiding Jan 22, 2025
5fefb6f
Merge branch 'ts-migration' of github.com:SiyaoIsHiding/nodejs-driver…
SiyaoIsHiding Jan 22, 2025
add7bcc
fix imports
SiyaoIsHiding Jan 22, 2025
965b456
for private publish
SiyaoIsHiding Jan 23, 2025
48ec973
can work with both esm and cjs syntax
SiyaoIsHiding Feb 7, 2025
c276779
run ts2esm. Still need to change export to export default {...}
SiyaoIsHiding Feb 12, 2025
1becd83
works! export both default and named. Works for both esm and cjs. Cjs…
SiyaoIsHiding Mar 4, 2025
e00a159
rm tsdoc-metadata.json
SiyaoIsHiding Mar 5, 2025
64787f2
Merge remote-tracking branch 'upstream/master' into ts-migration
SiyaoIsHiding Mar 5, 2025
f478589
delete ".js" in import
SiyaoIsHiding Mar 6, 2025
2f1eb9f
Update import syntax for tests. Pass tests except for constructor errors
SiyaoIsHiding Mar 11, 2025
3c1051f
add typescript eslint
SiyaoIsHiding Mar 13, 2025
9567a33
delete "use strict";
SiyaoIsHiding Mar 13, 2025
73ddf85
revert package name
SiyaoIsHiding Mar 13, 2025
9a30509
Fixing indentation
SiyaoIsHiding Mar 13, 2025
0fdf8b1
clear some eslint errors. delete index.d.ts
SiyaoIsHiding Mar 13, 2025
fc5e85f
add "@stylistic/eslint-plugin": "^3.1.0",
SiyaoIsHiding Mar 13, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# TypeScript: js files are generated using tsc transpiler
/test/unit/typescript/*.js
/test/unit/typescript/*

# Integer is part of the Closure Library
/lib/types/integer.js

# TinkerPop-based files
/lib/datastax/graph/type-serializers.js
/lib/datastax/graph/type-serializers.js

/out/**/*.js
10 changes: 9 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
module.exports = {
plugins: [
"@stylistic",
'@typescript-eslint'
],
parser: '@typescript-eslint/parser',
"env": {
"commonjs": true,
"es6": true
},
"parserOptions": {
"ecmaVersion": 2017
},
"extends": "eslint:recommended",
"extends": ["eslint:recommended", 'plugin:@typescript-eslint/recommended'],
"rules": {
"indent": [
"error",
Expand All @@ -33,6 +38,7 @@ module.exports = {
"array-callback-return": "error",
"curly": "error",
"no-unused-vars": ["error", { "args": "none" }],
"@typescript-eslint/no-unused-vars": ["error", { "args": "none" }],
"global-require": "error",
"eqeqeq": ["error", "allow-null"],

Expand Down Expand Up @@ -88,6 +94,8 @@ module.exports = {
allowShortCircuit: false,
allowTernary: false,
}],
"@typescript-eslint/no-this-alias": "off",
"@typescript-eslint/no-explicit-any": "off",
"no-useless-call": "off",
"no-useless-concat": "error",
"no-useless-escape": "error",
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,6 @@ out/
/docs
**/typescript/*.js
**/typescript/*.js.map
**/typescript/generated.ts
**/typescript/generated.ts

tsdoc-metadata.json
Loading