Is there a built-in way to bundle assets? #203
-
When I call I feel like this should this should work out-of-the-box; am I missing something? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
You can see asset bundling in action in this example - https://github.com/ptrdom/scalajs-esbuild/tree/main/sbt-scalajs-esbuild-web/examples/basic-web-project. Caveat is that the assets have to be imported inside source files - for example, "loose" assets that are referenced only in |
Beta Was this translation helpful? Give feedback.
You can see asset bundling in action in this example - https://github.com/ptrdom/scalajs-esbuild/tree/main/sbt-scalajs-esbuild-web/examples/basic-web-project. Caveat is that the assets have to be imported inside source files - for example, "loose" assets that are referenced only in
index.html
won't get put inside output directory. Only assets fromindex.html
that are picked up are entry point files -main.js
in the linked example case.