@gjsify/rolldown-plugin-pnp 0.4.27 → 0.4.29

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.
Files changed (2) hide show
  1. package/lib/index.js +5 -7
  2. package/package.json +1 -1
package/lib/index.js CHANGED
@@ -90,9 +90,7 @@ export async function pnpPlugin(opts = {}) {
90
90
  if (!importer)
91
91
  return null;
92
92
  // Importer may be a file URL string or an absolute path.
93
- const importerPath = importer.startsWith('file://')
94
- ? fileURLToPath(importer)
95
- : importer;
93
+ const importerPath = importer.startsWith('file://') ? fileURLToPath(importer) : importer;
96
94
  // Fast path: resolve from the importer's own context.
97
95
  try {
98
96
  const resolved = pnpApi.resolveRequest(source, importerPath);
@@ -158,8 +156,8 @@ export async function pnpPlugin(opts = {}) {
158
156
  };
159
157
  }
160
158
  function isUndeclaredDependency(err) {
161
- return typeof err === 'object'
162
- && err !== null
163
- && 'pnpCode' in err
164
- && err.pnpCode === 'UNDECLARED_DEPENDENCY';
159
+ return (typeof err === 'object' &&
160
+ err !== null &&
161
+ 'pnpCode' in err &&
162
+ err.pnpCode === 'UNDECLARED_DEPENDENCY');
165
163
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gjsify/rolldown-plugin-pnp",
3
- "version": "0.4.27",
3
+ "version": "0.4.29",
4
4
  "description": "Yarn PnP resolver plugin for Rolldown / Rollup / Vite",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",