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

Rename apps to packages directory in MF + SSR case #18849

Closed
1 of 4 tasks
tamtakoe opened this issue Aug 26, 2023 · 1 comment · Fixed by #18906
Closed
1 of 4 tasks

Rename apps to packages directory in MF + SSR case #18849

tamtakoe opened this issue Aug 26, 2023 · 1 comment · Fixed by #18906
Assignees
Labels
outdated scope: angular Issues related to Angular support in Nx type: bug

Comments

@tamtakoe
Copy link

Current Behavior

I create and run MF + SSR angular project and see:

Error: Failed to lookup view "index" in views directory ".../app-ssr/dist/apps/<app name>/browser"

It is because of error inside main.server.ts files

  const browserBundles = join(process.cwd(), 'dist/apps/<app name>/browser');
  const serverBundles = join(process.cwd(), 'dist/apps/<app name>/server');

should be

  const browserBundles = join(process.cwd(), 'dist/packages/<app name>/browser');
  const serverBundles = join(process.cwd(), 'dist/packages/<app name>/server');

Expected Behavior

No error

GitHub Repo

No response

Steps to Reproduce

npm install --global nx@latest
npx create-nx-workspace@latest app-ssr --preset=ts --nxCloud=false
cd app-ssr
npm install -D @nx/angular
npx nx g @nx/angular:host host --ssr --remotes=demo,ozon --e2eTestRunner="none" --style="scss"
nx serve-ssr host --devRemotes="demo,ozon"

Nx Report

Node   : 18.16.0
   OS     : darwin-x64
   npm    : 9.5.1

   nx (global)        : 16.7.4
   nx                 : 16.7.4
   @nx/js             : 16.7.4
   @nx/jest           : 16.7.4
   @nx/linter         : 16.7.4
   @nx/workspace      : 16.7.4
   @nx/angular        : 16.7.4
   @nx/cypress        : 16.7.4
   @nx/devkit         : 16.7.4
   @nx/eslint-plugin  : 16.7.4
   @nrwl/tao          : 16.7.4
   @nx/web            : 16.7.4
   @nx/webpack        : 16.7.4
   typescript         : 5.1.6
   ---------------------------------------
   Community plugins:
   @nguniversal/builders       : 16.2.0
   @nguniversal/express-engine : 16.2.0

Failure Logs

No response

Package Manager Version

No response

Operating System

  • macOS
  • Linux
  • Windows
  • Other (Please specify)

Additional Information

No response

@github-actions
Copy link

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 30, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated scope: angular Issues related to Angular support in Nx type: bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants