@canopy-iiif/app 1.8.7 → 1.8.8

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/lib/build/dev.js CHANGED
@@ -23,18 +23,13 @@ const APP_COMPONENTS_DIR = path.join(process.cwd(), "app", "components");
23
23
 
24
24
  function resolveTailwindCli() {
25
25
  const root = process.cwd();
26
- let cliEntry = null;
27
26
  try {
28
- cliEntry = require.resolve("@tailwindcss/cli/dist/index.mjs", { paths: [root] });
29
- } catch (_) {
30
- cliEntry = null;
31
- }
32
- if (cliEntry) {
33
- return { cmd: process.execPath || "node", args: [cliEntry] };
34
- }
35
- const binName = process.platform === "win32" ? "tailwindcss.cmd" : "tailwindcss";
36
- const bin = path.join(root, "node_modules", ".bin", binName);
37
- if (fs.existsSync(bin)) return { cmd: bin, args: [] };
27
+ const pkgPath = require.resolve("@tailwindcss/cli/package.json", { paths: [root] });
28
+ const cliEntry = path.join(path.dirname(pkgPath), "dist", "index.mjs");
29
+ if (fs.existsSync(cliEntry)) {
30
+ return { cmd: process.execPath || "node", args: [cliEntry] };
31
+ }
32
+ } catch (_) {}
38
33
  return null;
39
34
  }
40
35
  const PORT = Number(process.env.PORT || 5001);
@@ -9,18 +9,13 @@ const {
9
9
 
10
10
  function resolveTailwindCli() {
11
11
  const root = process.cwd();
12
- let cliEntry = null;
13
12
  try {
14
- cliEntry = require.resolve("@tailwindcss/cli/dist/index.mjs", { paths: [root] });
15
- } catch (_) {
16
- cliEntry = null;
17
- }
18
- if (cliEntry) {
19
- return {cmd: process.execPath || "node", args: [cliEntry]};
20
- }
21
- const binName = process.platform === "win32" ? "tailwindcss.cmd" : "tailwindcss";
22
- const localBin = path.join(root, "node_modules", ".bin", binName);
23
- if (fs.existsSync(localBin)) return {cmd: localBin, args: []};
13
+ const pkgPath = require.resolve("@tailwindcss/cli/package.json", {paths: [root]});
14
+ const cliEntry = path.join(path.dirname(pkgPath), "dist", "index.mjs");
15
+ if (fs.existsSync(cliEntry)) {
16
+ return {cmd: process.execPath || "node", args: [cliEntry]};
17
+ }
18
+ } catch (_) {}
24
19
  return null;
25
20
  }
26
21
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@canopy-iiif/app",
3
- "version": "1.8.7",
3
+ "version": "1.8.8",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "author": "Mat Jordan <mat@northwestern.edu>",