Skip to content

Commit

Permalink
Merge #1737
Browse files Browse the repository at this point in the history
1737: Fix package exports r=curquiza a=flevi29

# Pull Request

## Related issue
Fixes #1736

## PR checklist
Please check if your PR fulfills the following requirements:
- [x] Does this PR fix an existing issue, or have you listed the changes applied in the PR description (and why they are needed)?
- [x] Have you read the contributing guidelines?
- [x] Have you made sure that the title is accurate and descriptive of the changes?

Thank you so much for contributing to Meilisearch!


Co-authored-by: F. Levi <[email protected]>
  • Loading branch information
meili-bors[bot] and flevi29 authored Oct 4, 2024
2 parents 8f43b17 + 77f914b commit 03130bf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 11 deletions.
11 changes: 5 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@
"qdequele <[email protected]>"
],
"license": "MIT",
"main": "./dist/bundles/meilisearch.cjs.js",
"module": "./dist/bundles/meilisearch.esm.js",
"browser": "./dist/bundles/meilisearch.umd.js",
"main": "./dist/bundles/meilisearch.cjs",
"module": "./dist/bundles/meilisearch.mjs",
"typings": "./dist/types/index.d.ts",
"types": "./dist/types/index.d.ts",
"jsdelivr": "./dist/bundles/meilisearch.umd.js",
Expand All @@ -27,8 +26,8 @@
".": {
"types": "./dist/types/index.d.ts",
"browser": "./dist/bundles/meilisearch.umd.js",
"import": "./dist/bundles/meilisearch.esm.js",
"require": "./dist/bundles/meilisearch.cjs.js",
"import": "./dist/bundles/meilisearch.mjs",
"require": "./dist/bundles/meilisearch.cjs",
"default": "./dist/bundles/meilisearch.umd.js"
}
},
Expand Down Expand Up @@ -56,7 +55,7 @@
"test:env:nodejs": "yarn build && node tests/env/node/index.js && node tests/env/node/getting_started.js",
"test:env:esm": "yarn --cwd tests/env/esm && yarn --cwd tests/env/esm start",
"test:env:nitro-app": "yarn build && yarn --cwd tests/env/nitro-app test",
"size": "node scripts/file-size ./dist/bundles/meilisearch.esm.min.js ./dist/bundles/meilisearch.umd.min.js",
"size": "node scripts/file-size ./dist/bundles/meilisearch.mjs ./dist/bundles/meilisearch.umd.min.js",
"style": "yarn fmt && yarn lint",
"style:fix": "yarn fmt:fix && yarn lint:fix",
"fmt": "prettier -c ./**/*.{js,ts}",
Expand Down
8 changes: 3 additions & 5 deletions rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,7 @@ module.exports = [
sourcemap: env === "production", // create sourcemap for error reporting in production mode
},
],
plugins: [
env === "production" ? terser() : {}, // will minify the file in production mode
...PLUGINS,
],
plugins: PLUGINS,
},
// Common JS build (Node).
// Compatible only in a nodeJS environment.
Expand All @@ -102,7 +99,8 @@ module.exports = [
),
exports: "named",
format: "cjs",
sourcemap: env === "production", // create sourcemap for error reporting in production mode
},
plugins: [...PLUGINS],
plugins: PLUGINS,
},
];

0 comments on commit 03130bf

Please sign in to comment.