Skip to content

Commit

Permalink
Hide re-exported docs (bevyengine#1985)
Browse files Browse the repository at this point in the history
Solves bevyengine#1957 

Co-authored-by: caelumLaron <[email protected]>
  • Loading branch information
illuninocte and caelumLaron committed Apr 27, 2021
1 parent cc0ee53 commit b1ed28e
Show file tree
Hide file tree
Showing 19 changed files with 29 additions and 0 deletions.
1 change: 1 addition & 0 deletions crates/bevy_app/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ pub use plugin_group::*;
pub use schedule_runner::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
app::App, app_builder::AppBuilder, CoreStage, DynamicPlugin, Plugin, PluginGroup,
StartupStage,
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_asset/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ mod loader;
mod path;

pub mod prelude {
#[doc(hidden)]
pub use crate::{AddAsset, AssetEvent, AssetServer, Assets, Handle, HandleUntyped};
}

Expand Down
1 change: 1 addition & 0 deletions crates/bevy_audio/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ mod audio_output;
mod audio_source;

pub mod prelude {
#[doc(hidden)]
pub use crate::{Audio, AudioOutput, AudioSource, Decodable};
}

Expand Down
1 change: 1 addition & 0 deletions crates/bevy_core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ pub use task_pool_options::DefaultTaskPoolOptions;
pub use time::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{DefaultTaskPoolOptions, EntityLabels, Labels, Name, Time, Timer};
}

Expand Down
2 changes: 2 additions & 0 deletions crates/bevy_ecs/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,10 @@ pub mod system;
pub mod world;

pub mod prelude {
#[doc(hidden)]
#[cfg(feature = "bevy_reflect")]
pub use crate::reflect::ReflectComponent;
#[doc(hidden)]
pub use crate::{
bundle::Bundle,
entity::Entity,
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_input/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ use bevy_ecs::{
pub use input::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
gamepad::{
Gamepad, GamepadAxis, GamepadAxisType, GamepadButton, GamepadButtonType, GamepadEvent,
Expand Down
9 changes: 9 additions & 0 deletions crates/bevy_internal/src/prelude.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#[doc(hidden)]
pub use crate::{
app::prelude::*, asset::prelude::*, core::prelude::*, ecs::prelude::*, input::prelude::*,
log::prelude::*, math::prelude::*, reflect::prelude::*, scene::prelude::*,
Expand All @@ -6,26 +7,34 @@ pub use crate::{

pub use bevy_derive::bevy_main;

#[doc(hidden)]
#[cfg(feature = "bevy_audio")]
pub use crate::audio::prelude::*;

#[doc(hidden)]
#[cfg(feature = "bevy_pbr")]
pub use crate::pbr::prelude::*;

#[doc(hidden)]
#[cfg(feature = "bevy_render")]
pub use crate::render::prelude::*;

#[doc(hidden)]
#[cfg(feature = "bevy_sprite")]
pub use crate::sprite::prelude::*;

#[doc(hidden)]
#[cfg(feature = "bevy_text")]
pub use crate::text::prelude::*;

#[doc(hidden)]
#[cfg(feature = "bevy_ui")]
pub use crate::ui::prelude::*;

#[doc(hidden)]
#[cfg(feature = "bevy_dynamic_plugin")]
pub use crate::dynamic_plugin::*;

#[doc(hidden)]
#[cfg(feature = "bevy_gilrs")]
pub use crate::gilrs::*;
1 change: 1 addition & 0 deletions crates/bevy_log/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
mod android_tracing;

pub mod prelude {
#[doc(hidden)]
pub use bevy_utils::tracing::{
debug, debug_span, error, error_span, info, info_span, trace, trace_span, warn, warn_span,
};
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_math/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ pub use geometry::*;
pub use glam::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
BVec2, BVec3, BVec4, FaceToward, IVec2, IVec3, IVec4, Mat3, Mat4, Quat, Rect, Size, UVec2,
UVec3, UVec4, Vec2, Vec3, Vec4,
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_pbr/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ pub use light::*;
pub use material::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{entity::*, light::PointLight, material::StandardMaterial};
}

Expand Down
1 change: 1 addition & 0 deletions crates/bevy_reflect/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ mod impls {

pub mod serde;
pub mod prelude {
#[doc(hidden)]
pub use crate::{
reflect_trait, GetField, GetTupleStructField, Reflect, ReflectDeserialize, Struct,
TupleStruct,
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_render/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ use draw::{OutsideFrustum, Visible};
pub use once_cell;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
base::Msaa,
color::Color,
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_scene/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ pub use scene_loader::*;
pub use scene_spawner::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
DynamicScene, Scene, SceneSpawner, SpawnSceneAsChildCommands, SpawnSceneCommands,
};
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_sprite/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ mod texture_atlas;
mod texture_atlas_builder;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
entity::{SpriteBundle, SpriteSheetBundle},
ColorMaterial, Sprite, SpriteResizeMode, TextureAtlas, TextureAtlasSprite,
Expand Down
1 change: 1 addition & 0 deletions crates/bevy_tasks/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ mod iter;
pub use iter::ParallelIterator;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
iter::ParallelIterator,
slice::{ParallelSlice, ParallelSliceMut},
Expand Down
2 changes: 2 additions & 0 deletions crates/bevy_text/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ pub use text::*;
pub use text2d::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{Font, Text, Text2dBundle, TextAlignment, TextError, TextSection, TextStyle};
#[doc(hidden)]
pub use glyph_brush_layout::{HorizontalAlign, VerticalAlign};
}

Expand Down
1 change: 1 addition & 0 deletions crates/bevy_transform/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ pub mod hierarchy;
pub mod transform_propagate_system;

pub mod prelude {
#[doc(hidden)]
pub use crate::{components::*, hierarchy::*, TransformPlugin};
}

Expand Down
1 change: 1 addition & 0 deletions crates/bevy_ui/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ pub use render::*;
pub use ui_node::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{entity::*, ui_node::*, widget::Button, Anchors, Interaction, Margins};
}

Expand Down
1 change: 1 addition & 0 deletions crates/bevy_window/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ pub use window::*;
pub use windows::*;

pub mod prelude {
#[doc(hidden)]
pub use crate::{
CursorEntered, CursorLeft, CursorMoved, FileDragAndDrop, ReceivedCharacter, Window,
WindowDescriptor, WindowMoved, Windows,
Expand Down

0 comments on commit b1ed28e

Please sign in to comment.