Skip to content

Commit

Permalink
Merge pull request #6 from nextcloud-libraries/fix/cjs
Browse files Browse the repository at this point in the history
fix: ship a cjs bundle
  • Loading branch information
st3iny authored Jun 3, 2024
2 parents d00d231 + 1467a05 commit 4ee2210
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@
"url": "git+https://github.com/nextcloud-libraries/timezones.git"
},
"type": "module",
"main": "dist/index.mjs",
"main": "dist/index.cjs",
"exports": {
".": {
"import": "./dist/index.mjs"
"import": "./dist/index.mjs",
"require": "./dist/index.cjs"
},
"./resources/timezones/zones.json": "./resources/timezones/zones.json"
},
Expand Down
1 change: 1 addition & 0 deletions vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { createLibConfig } from '@nextcloud/vite-config'
export default createLibConfig({
index: 'src/index.js',
}, {
libraryFormats: ['es', 'cjs'],
config: {
test: {
setupFiles: [
Expand Down

0 comments on commit 4ee2210

Please sign in to comment.