prettier-plugin-sh
Advanced tools
Comparing version 0.10.1 to 0.10.2
@@ -5,6 +5,7 @@ import path from 'path'; | ||
import { languages } from './languages.js'; | ||
const _dirname = typeof __dirname === 'undefined' | ||
const isInModule = typeof __dirname === 'undefined'; | ||
const _dirname = isInModule | ||
? path.dirname(fileURLToPath(import.meta.url)) | ||
: __dirname; | ||
const workerPath = path.resolve(_dirname, '../worker.mjs'); | ||
const workerPath = path.resolve(_dirname, `../worker.${isInModule ? 'mjs' : 'cjs'}`); | ||
const processorSync = createSyncFn(workerPath); | ||
@@ -11,0 +12,0 @@ const handleError = (fn) => { |
{ | ||
"name": "prettier-plugin-sh", | ||
"version": "0.10.1", | ||
"version": "0.10.2", | ||
"type": "module", | ||
@@ -16,5 +16,5 @@ "description": "An opinionated `shellscript、Dockerfile、properties、gitignore、dotenv、hosts、jvmoptions...` formatter plugin for Prettier", | ||
"exports": { | ||
"types": "./lib/index.d.ts", | ||
"import": "./lib/index.js", | ||
"require": "./lib/index.cjs", | ||
"types": "./lib/index.d.ts" | ||
"require": "./lib/index.cjs" | ||
}, | ||
@@ -24,2 +24,3 @@ "types": "./lib/index.d.ts", | ||
"lib", | ||
"worker.cjs", | ||
"worker.mjs" | ||
@@ -26,0 +27,0 @@ ], |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1193
43171