@nxworker/workspace
Version:
Nx plugin providing generators for managing workspace files, including the move-file generator for safely moving files between projects while updating all imports
23 lines (22 loc) • 902 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "getFallbackEntryPointPaths", {
enumerable: true,
get: function() {
return getFallbackEntryPointPaths;
}
});
const _nodepath = require("node:path");
const _buildfilenames = require("../path-utils/build-file-names");
const _fileextensions = require("../constants/file-extensions");
const primaryEntryFilenames = (0, _buildfilenames.buildFileNames)(_fileextensions.primaryEntryBaseNames);
function getFallbackEntryPointPaths(project) {
const sourceRoot = project.sourceRoot || project.root;
return [
...primaryEntryFilenames.map((fileName)=>_nodepath.posix.join(sourceRoot, fileName)),
...primaryEntryFilenames.map((fileName)=>_nodepath.posix.join(project.root, 'src', fileName))
];
}
//# sourceMappingURL=get-fallback-entry-point-paths.js.map