diff --git a/projects/js-packages/scan/src/index.ts b/projects/js-packages/scan/src/index.ts index 8009266228a9b..316fb8ba3871d 100644 --- a/projects/js-packages/scan/src/index.ts +++ b/projects/js-packages/scan/src/index.ts @@ -1,3 +1,3 @@ -export * from './types/index.js'; -export * from './constants/index.js'; -export * from './utils/index.js'; +export * from './types'; +export * from './constants'; +export * from './utils'; diff --git a/projects/js-packages/scan/src/types/index.ts b/projects/js-packages/scan/src/types/index.ts index e831f787e4b42..7f9ff96cb85c5 100644 --- a/projects/js-packages/scan/src/types/index.ts +++ b/projects/js-packages/scan/src/types/index.ts @@ -1,2 +1,2 @@ -export * from './fixers.js'; -export * from './threats.js'; +export * from './fixers'; +export * from './threats'; diff --git a/projects/js-packages/scan/src/types/threats.ts b/projects/js-packages/scan/src/types/threats.ts index 016e2e1eaee51..dca016203c4b9 100644 --- a/projects/js-packages/scan/src/types/threats.ts +++ b/projects/js-packages/scan/src/types/threats.ts @@ -1,4 +1,4 @@ -import { ThreatFixStatus } from './fixers.js'; +import { ThreatFixStatus } from '..'; export type ThreatStatus = 'fixed' | 'ignored' | 'current'; diff --git a/projects/js-packages/scan/src/utils/index.ts b/projects/js-packages/scan/src/utils/index.ts index fae955b0507fb..1c727460eff03 100644 --- a/projects/js-packages/scan/src/utils/index.ts +++ b/projects/js-packages/scan/src/utils/index.ts @@ -1,6 +1,4 @@ -import { FIXER_IS_STALE_THRESHOLD } from '../constants/index.js'; -import { ThreatFixStatus } from '../types/fixers.js'; -import { Threat } from '../types/threats.js'; +import { Threat, ThreatFixStatus, FIXER_IS_STALE_THRESHOLD } from '..'; export const getThreatType = ( threat: Threat ) => { if ( threat.signature === 'Vulnerable.WP.Core' ) { @@ -26,6 +24,6 @@ export const fixerStatusIsStale = ( fixerStatus: ThreatFixStatus ) => { return ( 'status' in fixerStatus && fixerStatus.status === 'in_progress' && - fixerTimestampIsStale( fixerStatus.last_updated ) + fixerTimestampIsStale( fixerStatus.lastUpdated ) ); }; diff --git a/projects/js-packages/scan/tsconfig.json b/projects/js-packages/scan/tsconfig.json index 763a299b661f0..2ad7ab8c19092 100644 --- a/projects/js-packages/scan/tsconfig.json +++ b/projects/js-packages/scan/tsconfig.json @@ -5,6 +5,7 @@ "typeRoots": [ "./node_modules/@types/", "src/types/*" ], "sourceMap": false, "outDir": "./build/", - "target": "esnext" + "module": "ESNext", + "moduleResolution": "bundler" } }