Skip to content

Commit 03046aa

Browse files
committed
convert to esm and node24
1 parent 225f625 commit 03046aa

File tree

125 files changed

+688
-1087
lines changed

Some content is hidden

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

125 files changed

+688
-1087
lines changed

CONTRIBUTORS.js renamed to CONTRIBUTORS.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Currently this will cause the /players/:id endpoint to return is_contributor = true for your profile
55
*/
66

7-
module.exports = {
7+
export default {
88
88367253: {}, // howardchung
99
102344608: {}, // albertcui
1010
9977887: {}, // gu3st

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM node:22
1+
FROM node:24
22

33
ENV NPM_CONFIG_LOGLEVEL warn
44

Dockerfile.retriever

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,11 @@ ENV NPM_CONFIG_LOGLEVEL warn
1212
COPY proto /usr/src/proto
1313
COPY svc/retriever.ts /usr/src/svc/retriever.ts
1414
COPY config.ts /usr/src/config.ts
15-
COPY index.ts /usr/src/index.ts
15+
#COPY index.ts /usr/src/index.ts
1616
COPY package.retriever.json /usr/src/package.json
1717
WORKDIR /usr/src
1818
RUN npm install
1919

2020
ENV PATH /usr/src/node_modules/.bin:$PATH
2121

22-
ENV ROLE retriever
23-
2422
CMD ["npm", "start"]

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
- Start containers and initialize databases: `docker-compose up`
2626
- Make some changes and commit them.
2727
- Submit a pull request. Wait for it to be reviewed and merged.
28-
- **OPTIONAL** Add your DOTA friend code (SteamId3) to the `CONTRIBUTORS.js` file.
28+
- **OPTIONAL** Add your DOTA friend code (SteamId3) to the `CONTRIBUTORS.ts` file.
2929
- Congratulations! You're a contributor.
3030

3131
## Notes

dev/archiveTest.mts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { archivedFetcher } from '../svc/fetcher/getArchivedData.js';
1+
import { archivedFetcher } from '../svc/fetcher/getArchivedData.ts';
22

3-
const { matchArchive } = await import('../svc/store/archive.js');
3+
const { matchArchive } = await import('../svc/store/archive.ts');
44

55
// Read some match data
66
// const match = await getMatchDataFromBlob(7465883253);

dev/convertSpec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
import fs from 'fs';
2-
import spec from '../svc/api/spec';
2+
import spec from '../svc/api/spec.ts';
33

44
fs.writeFileSync('./spec.json', JSON.stringify(spec, null, 2), 'utf-8');

dev/copyUsage.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import db from '../svc/store/db';
1+
import db from '../svc/store/db.ts';
22
import moment from 'moment';
33

44
async function start() {

dev/findProMatches.mts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
const { insertMatch } = await import('../svc/util/insert.js');
2-
const { db } = await import('../svc/store/db.js');
1+
const { insertMatch } = await import('../svc/util/insert.ts');
2+
const { db } = await import('../svc/store/db.ts');
33
const { getSteamAPIData, SteamAPIUrls } = await import(
4-
'../svc/util/utility.js'
4+
'../svc/util/utility.ts'
55
);
66

77
async function getPage(url: string, leagueid: number) {

dev/fixProMatches.mts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
const { insertMatch } = await import('../svc/util/insert.js');
2-
const { db } = await import('../svc/store/db.js');
1+
const { insertMatch } = await import('../svc/util/insert.ts');
2+
const { db } = await import('../svc/store/db.ts');
33
const { SteamAPIUrls, getSteamAPIData, isProMatch } = await import(
4-
'../svc/util/utility.js'
4+
'../svc/util/utility.ts'
55
);
66

77
// From DB

dev/generateFakeRatings.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const { db } = await import('../svc/store/db.js');
1+
const { db } = await import('../svc/store/db.ts');
22

33
function randByCentralLimitTheorem() {
44
let v = 0;

0 commit comments

Comments
 (0)