You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was able to get it past the --preserve-symlinks error, but now I have a new error and I'm not sure what to do about it.
I feel like the npm modules should be able to be bundled. It kind of defeats the purpose for me if I can't bundle the npm modules.
Error
INFO: Invocation ID: 3c7403f6-0e2d-4c23-90b5-4da687d6b7c5
INFO: Analyzed target //:bundle (2 packages loaded, 8 targets configured).
INFO: Found 1 target...
ERROR: workspace/BUILD.bazel:27:8: Bundling Javascript index.mjs [esbuild] failed (Exit 1) esbuild failed: error executing command external/esbuild_darwin/bin/esbuild --bundle bazel-out/darwin-fastbuild/bin/index.mjs --sourcemap --preserve-symlinks '--platform=browser' '--target=es2015' '--log-level=info' ... (remaining 6 argument(s) skipped)
Use --sandbox_debug to see verbose messages from the sandbox
> bazel-out/darwin-fastbuild/bin/index.mjs: error: Could not resolve "react" (mark it as external to exclude it from the bundle)
1 │ import React from "react";
╵ ~~~~~~~
> bazel-out/darwin-fastbuild/bin/index.mjs: error: Could not resolve "react-dom" (mark it as external to exclude it from the bundle)
2 │ import ReactDOM from "react-dom";
╵ ~~~~~~~~~~~
2 errors
Target //:bundle failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 0.516s, Critical Path: 0.20s
INFO: 2 processes: 2 internal.
FAILED: Build did NOT complete successfully
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
This issue follows this issue.
I was able to get it past the
--preserve-symlinks
error, but now I have a new error and I'm not sure what to do about it.I feel like the npm modules should be able to be bundled. It kind of defeats the purpose for me if I can't bundle the npm modules.
Error
Things I tried
(reference my setup here)
es5_sources
filegroup and used that indeps
instead of:lib
@npm//react
and@npm//react-dom
todeps
devmode_
andprodmode_
module and target toesnext
andes2015
, respectivelyThe text was updated successfully, but these errors were encountered: