Skip to content

Commit

Permalink
build: add "esModuleInterop": true to fix import issue (#171)
Browse files Browse the repository at this point in the history
  • Loading branch information
ahonn authored Sep 18, 2024
1 parent 25db1b4 commit cb5574a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion backend/src/decorators/plimit.decorator.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as pLimit from 'p-limit';
import pLimit from 'p-limit';

export interface PLimitOptions {
concurrency: number;
Expand Down
2 changes: 1 addition & 1 deletion backend/src/modules/rgbpp/statistic/statistic.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Inject, Injectable, Logger } from '@nestjs/common';
import { CACHE_MANAGER, Cache } from '@nestjs/cache-manager';
import { ONE_DAY_MS } from 'src/common/date';
import { CkbRpcWebsocketService } from 'src/core/ckb-rpc/ckb-rpc-websocket.service';
import * as pLimit from 'p-limit';
import pLimit from 'p-limit';
import { BI } from '@ckb-lumos/bi';
import { CkbScriptService } from 'src/modules/ckb/script/script.service';
import { CellType } from 'src/modules/ckb/script/script.model';
Expand Down
5 changes: 4 additions & 1 deletion backend/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"removeComments": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"resolveJsonModule": true,
"target": "ES2021",
Expand All @@ -19,5 +20,7 @@
"forceConsistentCasingInFileNames": false,
"noFallthroughCasesInSwitch": false
},
"exclude": ["dist"]
"exclude": [
"dist"
]
}

0 comments on commit cb5574a

Please sign in to comment.