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

[Bug]: Unexpected token ':' #520

Closed
dilbarov opened this issue Feb 20, 2024 · 6 comments
Closed

[Bug]: Unexpected token ':' #520

dilbarov opened this issue Feb 20, 2024 · 6 comments

Comments

@dilbarov
Copy link

What happened?

When I use the module in SSR, I get a SyntaxError: Unexpected token ':' error

Version

v16.0.1

Angular Version

v17.1.1

What browsers are you seeing the problem on?

Chrome

Link to reproduce

No response

Relevant log output

[vite] Error when evaluating SSR module /main.server.mjs:
|- SyntaxError: Unexpected token ':'
    at new AsyncFunction (<anonymous>)
    at instantiateModule (file:///some-project/node_modules/vite/dist/node/chunks/dep-9A4-l-43.js:50858:28)

Willing to submit a PR?

None

@sibiraj-s
Copy link
Owner

SSR is not supported as the editor heavily relies on client side api's to work.

@dilbarov
Copy link
Author

SSR is not supported as the editor heavily relies on client side api's to work.

This worked fine in version 15

@sibiraj-s
Copy link
Owner

sibiraj-s commented Feb 20, 2024

Not really sure whats changed here. The library side changes are very minor.

Few noticeable things between 15-16 are

  1. added trusted types support
  2. set package sideEffects to false
  3. Angular 16 support.

Since it was not intended to be SSR compatible, never tested there.

@dilbarov
Copy link
Author

The problem is in the build with vite in dev mode. There is an error with the prose mirror library.Because this construct does not work in strict mode.

Issue can be closed

@sibiraj-s
Copy link
Owner

Thanks for figuring this out.

Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in the thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants