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

package --js --library (incorrectly) requires a main class to be present. #915

Closed
rmgk opened this issue Apr 20, 2022 · 0 comments · Fixed by #941
Closed

package --js --library (incorrectly) requires a main class to be present. #915

rmgk opened this issue Apr 20, 2022 · 0 comments · Fixed by #941
Labels
bug Something isn't working

Comments

@rmgk
Copy link

rmgk commented Apr 20, 2022

Version(s)

0.1.3, 0.1.4

Describe the bug

scala-cli package --js --library test.scala produces [error] No main class found if there is no main class in test.scala.
Thus, no output is generated at all.

To Reproduce

sample test.scala for the above command.

object Main { val x = 4 }

Expected behaviour

This works with scala-cli package --library test.scala (i.e., no --js) and js packaging also works if one provides an empty main class, thus I would expect the js library to produce working output even if there is no main class.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants