aspect-build / aspect-build/rules_webpack

Remove setting entry point[s] config, only declare outputs

Open
#108 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Starlark
Stars
33
Forks
20
PR merge metrics
No merged PRs in 30d

Description

Today `webpack_bundle` modifies the base config file entering the `entry_point[s]`, however sometimes the user wants to set them manually within the webpack config such as dynamic entries while outputting a directory.

The various combinations of `entry_point[s]`, `output_dir` and settings in the user webpack.config have too many conflicting combinations creating a confusing API, unnecessary logic within the rule etc.

Proposed API: the rule `name`, `entry_point[s]`, `output_dir` are only used to specify what the webpack config will output to allow bazel to declare outputs. Setting the entries must be done by the user within the webpack config.

Contributor guide

Open the contributing guide

Research direction

Start by locating the webpack_bundle rule and tracing how entry_point[s], output_dir, and the user webpack.config are combined. Review the existing combinations and define the behavior for the proposed API, then verify that entries are supplied by the user config while the rule still declares the intended outputs.

Written by the indexing model from the issue text.

Assessment

Tech stack
webpack
Domain
build-system
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.