resuml 1.5.0 → 1.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "resuml",
3
- "version": "1.5.0",
3
+ "version": "1.5.1",
4
4
  "description": "Generate JSON resumes from YAML with theme support",
5
5
  "type": "module",
6
6
  "main": "./dist/api.js",
@@ -100,6 +100,13 @@ async function bundleTheme(shortName, packageName) {
100
100
  format: 'esm',
101
101
  target: 'es2022',
102
102
  platform: 'browser',
103
+ // Use 'require' condition so packages like underscore/lodash resolve to their
104
+ // CJS/UMD builds (which export a callable function) instead of their ESM builds
105
+ // (which export a namespace object that breaks _(collection) call syntax).
106
+ conditions: ['browser', 'require', 'default'],
107
+ // Prefer the CJS 'main' field over the ESM 'module' field for packages
108
+ // that don't use the exports map (older packages).
109
+ mainFields: ['browser', 'main'],
103
110
  outfile: resolve(THEMES_DIR, `${shortName}.js`),
104
111
  define: {
105
112
  'process.env.NODE_ENV': '"production"',