1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
[]
= "bevy_react_core"
= true
= true
= "The core bridge of bevy-react (drive bevy_ui from React over an embedded V8 runtime). Apps depend on the `bevy-react` crate."
= true
= true
= true
= true
= "../../README.md"
= ["bevy", "react", "ui", "gamedev", "gui"]
= ["gui", "game-development"]
# docs.rs documents the default (native) target. `rusty_v8` (via deno_core) skips
# its network V8 download when the `DOCS_RS` env var is set, so the native build
# succeeds without network access.
[]
= true
= ["--cfg", "docsrs"]
[]
= "bevy_react_core"
= "src/lib.rs"
# The devtools inspector (auto-registered by `ReactUiPlugin`, `<root>`-hosted
# panel). A default feature: consumers get devtools in dev builds with zero
# setup (the plugin is inert in `--release` builds); size-conscious release
# builds compile it out with `default-features = false`.
[]
= ["devtools"]
= []
# Named custom image cursors (`ReactUiPlugin::cursor`). Turns on
# `bevy/custom_cursor`, which pulls in `bevy_winit` — so a build with it needs
# a winit backend (`bevy/x11` or `bevy/wayland` on Linux; every windowed app
# has one). Not a default here, so a standalone core build/test stays
# winit-free; the `bevy-react` facade turns it on by default.
= ["bevy/custom_cursor"]
# SVG `<text>` support in file-mode SVGs (`<image src="x.svg">`): pulls in
# usvg's font machinery (fontdb + a system-font scan). Off by default — most
# icon/illustration SVGs have no text. usvg splits the two halves: `text` is
# shaping (fontdb + rustybuzz), `system-fonts` is fontdb's filesystem scan —
# loading system fonts needs both.
= ["usvg/text", "usvg/system-fonts"]
# The headless op harness (`bevy_react_core::test_util`) for a feature crate's
# own tests: unstable, dev-dependency only.
= []
[]
= { = true }
# Exactly what the code references (no transitive shortcuts: the list
# documents what the crate touches and survives bevy reshuffling its feature
# graph). Cargo unifies features, so each of these also decides what the
# app's `DefaultPlugins` contains — never add one the code doesn't need.
= { = true, = [
"std",
"bevy_asset",
"bevy_image",
"bevy_color",
"bevy_window",
"bevy_camera",
"bevy_mesh",
"bevy_shader",
"bevy_render",
"bevy_core_pipeline",
# Only for the camera gate's ordering against
# `UpdateDirectionalLightCascades` (plugin.rs) — required, not optional:
# our `cfg` can't see the app's bevy features, and an app with 3D lights
# needs the ordering.
"bevy_light",
"bevy_ui",
"bevy_ui_render",
"bevy_ui_widgets",
"bevy_input_focus",
"bevy_text",
"bevy_picking",
"keyboard",
"mouse",
"touch",
"gamepad",
# Not referenced by the code, but bevy-react is broken without them at
# runtime: no UI pointer hits (no clicks/hover), invisible text unless a
# font is configured, and `<editableText>` copy/paste confined to the app.
"ui_picking",
"default_font",
"system_clipboard",
] }
= { = true }
= { = true }
= { = true }
= { = true }
= { = true }
= { = true }
= { = true }
= { = true }
= { = true }
= { = true }
= { = true }
# `no-serde-warnings`: the `#[react_*]` macros route serde through
# `#[serde(crate = "…::__private::serde")]` (so callers need no direct serde
# dependency), and ts-rs 10's serde-compat parser warns on that key at every
# expansion. ts-rs 12 parses it silently — drop the feature on upgrade.
= { = true, = ["no-serde-warnings"] }
# Native host: the embedded V8 isolate (deno_core) on a dedicated thread, driven by
# a tokio current-thread runtime. Neither builds for wasm.
[]
= { = true }
= { = true }
= { = true }
# Web host: React runs in the browser's own engine, reached over wasm-bindgen.
[]
= { = true }
= { = true }
= { = true }
= { = true }
= { = true, = ["console"] }
= { = true }
# Bevy/rand pull `getrandom`; on wasm it needs the browser backend enabled (the
# `wasm_js` feature plus `--cfg getrandom_backend="wasm_js"`, set in .cargo/config.toml).
= { = true, = ["wasm_js"] }
[]
# Parse/validate the crate's WGSL in unit tests. Already in the dependency
# tree via bevy's wgpu; the version requirement must keep resolving to that
# same copy.
= { = "29.0", = ["wgsl-in"] }
= { = true }