Add configuration to automatically disable/enable features when running in the web #250
Labels
A-Build
Related to the bevy build command
A-Run
Related to the bevy run command
A-Web
Building or running Bevy apps targeting the browser
C-Usability
An improvement that makes the API more pleasant
D-Modest
A "normal" level of difficulty; suitable for simple features or challenging fixes
We should provide an option to automatically disable default features and enable features when running the app on the web.
For example, via a
package.metadata.bevy_cli.web.default-features = false
configuration inCargo.toml
.Use case: Some features, like file watching, are only available on native platforms.
It's convenient to have them enabled by default, so that
cargo run
gives you hot asset reloading.But then we have to always add
--no-default-features
when runningbevy run web
, which is a regression in TheBevyFlock/bevy_new_2d#312.It would be nice if we could permanently configure it instead so the user doesn't have to type it out every time.
CLI options should take precedence over the
Cargo.toml
configuration.The text was updated successfully, but these errors were encountered: