hammoc 1.0.2 → 1.0.3
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
package/scripts/postinstall.cjs
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
// Link @
|
|
4
|
+
// Link @hammoc/shared into node_modules after npm install.
|
|
5
5
|
// In workspace (development) mode, npm handles this via symlinks.
|
|
6
6
|
// In global/standalone install, we need to create the link manually
|
|
7
|
-
// so the server can resolve `import ... from '@
|
|
7
|
+
// so the server can resolve `import ... from '@hammoc/shared'`.
|
|
8
8
|
|
|
9
9
|
const fs = require('fs');
|
|
10
10
|
const path = require('path');
|
|
11
11
|
|
|
12
12
|
const root = path.resolve(__dirname, '..');
|
|
13
13
|
const sharedPkg = path.resolve(root, 'packages', 'shared');
|
|
14
|
-
const nmScope = path.resolve(root, 'node_modules', '@
|
|
14
|
+
const nmScope = path.resolve(root, 'node_modules', '@hammoc');
|
|
15
15
|
const nmTarget = path.resolve(nmScope, 'shared');
|
|
16
16
|
|
|
17
17
|
// Only create link if shared package exists in tarball but not in node_modules
|