From 2e341d2cb80c430de5511f22991ffe82fc94e6ad Mon Sep 17 00:00:00 2001 From: Snorre Eskeland Brekke Date: Fri, 13 Jan 2023 13:10:48 +0100 Subject: [PATCH] fix: changed order of import and require --- src/actions/verify/validations.ts | 2 +- src/npm/package.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/actions/verify/validations.ts b/src/actions/verify/validations.ts index 8d7dfe8c..53eb2984 100644 --- a/src/actions/verify/validations.ts +++ b/src/actions/verify/validations.ts @@ -63,8 +63,8 @@ export function validateModule(packageJson: PackageJson, options: {outDir: strin ".": { "types": "./${outDir}/index.d.ts", "source": "./src/index.ts", - "import": "./${outDir}/index.esm.js", "require": "./${outDir}/index.js", + "import": "./${outDir}/index.esm.js", "default": "./${outDir}/index.js" } }, diff --git a/src/npm/package.ts b/src/npm/package.ts index 808dc547..e4b4d341 100644 --- a/src/npm/package.ts +++ b/src/npm/package.ts @@ -296,8 +296,8 @@ export async function writePackageJson(data: PackageData, options: InjectOptions '.': { ...(flags.typescript ? {types: `./${outDir}/index.d.ts`} : {}), source, - import: `./${outDir}/index.esm.js`, require: `./${outDir}/index.js`, + import: `./${outDir}/index.esm.js`, default: `./${outDir}/index.esm.js`, }, './package.json': './package.json',