@travetto/manifest 5.0.4 → 5.0.5

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/README.md CHANGED
@@ -91,7 +91,8 @@ By default, all paths within the framework are assumed to be in a POSIX style, a
91
91
  "compilerUrl": "http://127.0.0.1:26803",
92
92
  "compilerModuleFolder": "module/compiler",
93
93
  "outputFolder": ".trv/output",
94
- "toolFolder": ".trv/tool"
94
+ "toolFolder": ".trv/tool",
95
+ "typesFolder": ".trv/types"
95
96
  },
96
97
  "main": {
97
98
  "name": "@travetto/manifest",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@travetto/manifest",
3
- "version": "5.0.4",
3
+ "version": "5.0.5",
4
4
  "description": "Support for project indexing, manifesting, along with file watching",
5
5
  "keywords": [
6
6
  "path",
package/src/context.ts CHANGED
@@ -53,14 +53,15 @@ function findPackage(dir: string): Pkg {
53
53
  * Get workspace root
54
54
  */
55
55
  function resolveWorkspace(base: string = process.cwd()): Workspace {
56
- if (base in WS_ROOT) { return WS_ROOT[base]; }
56
+ if (base in WS_ROOT) {
57
+ return WS_ROOT[base];
58
+ }
57
59
  let folder = base;
58
- let prev;
59
- /** @type {Pkg|undefined} */
60
- let prevPkg, pkg;
60
+ let prev: string | undefined;
61
+ let pkg: Pkg | undefined;
61
62
 
62
63
  while (prev !== folder) {
63
- [prev, prevPkg] = [folder, pkg];
64
+ prev = folder;
64
65
  pkg = readPackage(folder) ?? pkg;
65
66
  if (
66
67
  (pkg && (!!pkg.workspaces || !!pkg.travetto?.build?.isolated)) || // if we have a monorepo root, or we are isolated
@@ -82,7 +83,7 @@ function resolveWorkspace(base: string = process.cwd()): Workspace {
82
83
  manager: existsSync(path.resolve(pkg.path, 'yarn.lock')) ? 'yarn' : 'npm',
83
84
  resolve: createRequire(`${pkg.path}/node_modules`).resolve.bind(null),
84
85
  stripRoot: (full) => full === pkg.path ? '' : full.replace(`${pkg.path}/`, ''),
85
- mono: !!pkg.workspaces || (!pkg.travetto?.build?.isolated && !!prevPkg) // Workspaces or nested projects
86
+ mono: !!pkg.workspaces
86
87
  };
87
88
  }
88
89