Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Nx patches/issues #15

Open
layershifter opened this issue Jan 20, 2022 · 0 comments
Open

chore: Nx patches/issues #15

layershifter opened this issue Jan 20, 2022 · 0 comments
Assignees

Comments

@layershifter
Copy link
Member

layershifter commented Jan 20, 2022

We have few issues with Nx where bugs are present or something work as not expected. Temporary this is solved with patches via yarn, but it's not a long term solution.

Issue with entrypoints

--- a/src/executors/rollup/rollup.impl.js
+++ b/src/executors/rollup/rollup.impl.js
@@ -209,7 +209,7 @@ function createCompilerOptions(options, dependencies) {
function updatePackageJson(options, context, target, dependencies, packageJson) {
const entryFileTmpl = `./index.<%= extension %>.js`;
const typingsFile = (0, path_1.relative)(options.entryRoot, options.entryFile).replace(/\.[jt]sx?$/, '.d.ts');
- packageJson.main = entryFileTmpl.replace('<%= extension %>', 'umd');
+ packageJson.main = entryFileTmpl.replace('<%= extension %>', 'cjs');
packageJson.module = entryFileTmpl.replace('<%= extension %>', 'esm');
packageJson.typings = `./${typingsFile}`;
(0, devkit_1.writeJsonFile)(`${options.outputPath}/package.json`, packageJson);

NX issue: nrwl/nx#8505

Dependencies for packages are collected recursively

--- a/src/utils/check-dependencies.js
+++ b/src/utils/check-dependencies.js
@@ -5,7 +5,7 @@ const devkit_1 = require("@nrwl/devkit");
const buildable_libs_utils_1 = require("@nrwl/workspace/src/utilities/buildable-libs-utils");
function checkDependencies(context, tsConfigPath) {
const projectGraph = (0, devkit_1.readCachedProjectGraph)();
- const { target, dependencies, nonBuildableDependencies } = (0, buildable_libs_utils_1.calculateProjectDependencies)(projectGraph, context.root, context.projectName, context.targetName, context.configurationName);
+ const { target, dependencies, nonBuildableDependencies } = (0, buildable_libs_utils_1.calculateProjectDependencies)(projectGraph, context.root, context.projectName, context.targetName, context.configurationName, true);
const projectRoot = target.data.root;
if (nonBuildableDependencies.length > 0) {
throw new Error(`Buildable libraries can only depend on other buildable libraries. You must define the ${context.targetName} target for the following libraries: ${nonBuildableDependencies

NX issue: nrwl/nx#9371

Typecheck results are invalid in @nrwl/web:rollup

nrwl/nx#9053

@layershifter layershifter changed the title Nx patches Nx patches/issues Feb 21, 2022
@layershifter layershifter self-assigned this Feb 23, 2022
@layershifter layershifter changed the title Nx patches/issues chore: Nx patches/issues Jul 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant