mirror of
https://github.com/adoyle0/leptos-use.git
synced 2025-01-23 00:59:22 -05:00
parent
fb1ac55ac7
commit
e31709ba84
15 changed files with 24 additions and 2 deletions
|
@ -13,7 +13,7 @@ repository = "https://github.com/Synphonyte/leptos-use"
|
|||
homepage = "https://leptos-use.rs"
|
||||
|
||||
[dependencies]
|
||||
leptos = "0.5.0-beta2"
|
||||
leptos = "0.5.0-rc1"
|
||||
wasm-bindgen = "0.2"
|
||||
js-sys = "0.3"
|
||||
default-struct-builder = "0.5"
|
||||
|
|
|
@ -5,7 +5,7 @@ use leptos_use::signal_throttled;
|
|||
#[component]
|
||||
fn Demo() -> impl IntoView {
|
||||
let (input, set_input) = create_signal("".to_string());
|
||||
let throttled = signal_throttled(input, 1000.0);
|
||||
let throttled: Signal<String> = signal_throttled(input, 1000.0);
|
||||
|
||||
view! {
|
||||
<div>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
#[tokio::main]
|
||||
async fn main() {
|
||||
use axum::{routing::post, Router};
|
||||
use leptos::logging::log;
|
||||
use leptos::*;
|
||||
use leptos_axum::{generate_route_list, LeptosRoutes};
|
||||
use start_axum::app::*;
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
use leptos::ev::{click, keydown};
|
||||
use leptos::html::A;
|
||||
use leptos::logging::log;
|
||||
use leptos::*;
|
||||
use leptos_use::use_event_listener;
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
use leptos::html::Div;
|
||||
use leptos::logging::log;
|
||||
use leptos::*;
|
||||
use leptos_use::docs::{demo_or_body, BooleanDisplay};
|
||||
use leptos_use::{use_scroll_with_options, ScrollBehavior, UseScrollOptions, UseScrollReturn};
|
||||
|
|
|
@ -25,6 +25,7 @@ static IOS_WORKAROUND: RwLock<bool> = RwLock::new(false);
|
|||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::ev::resize;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos::html::Div;
|
||||
/// # use leptos_use::on_click_outside;
|
||||
/// #
|
||||
|
|
|
@ -17,6 +17,7 @@ use web_sys::AddEventListenerOptions;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// use leptos_use::use_active_element;
|
||||
/// #
|
||||
/// # #[component]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
use crate::use_media_query;
|
||||
use leptos::logging::error;
|
||||
use leptos::*;
|
||||
use paste::paste;
|
||||
use std::collections::HashMap;
|
||||
|
|
|
@ -12,6 +12,7 @@ use leptos::*;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// use leptos_use::{use_cycle_list, UseCycleListReturn};
|
||||
/// #
|
||||
/// # #[component]
|
||||
|
|
|
@ -16,6 +16,7 @@ use wasm_bindgen::JsCast;
|
|||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::ev::visibilitychange;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::use_event_listener;
|
||||
/// #
|
||||
/// # #[component]
|
||||
|
@ -33,6 +34,7 @@ use wasm_bindgen::JsCast;
|
|||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::ev::click;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::use_event_listener;
|
||||
/// #
|
||||
/// # #[component]
|
||||
|
@ -61,6 +63,7 @@ use wasm_bindgen::JsCast;
|
|||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::ev::keydown;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use web_sys::KeyboardEvent;
|
||||
/// # use leptos_use::use_event_listener;
|
||||
/// #
|
||||
|
|
|
@ -12,6 +12,7 @@ use leptos::*;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::watch_debounced;
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
@ -35,6 +36,7 @@ use leptos::*;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::{watch_debounced_with_options, WatchDebouncedOptions};
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
|
|
@ -11,6 +11,7 @@ use leptos::*;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::{watch_pausable, WatchPausableReturn};
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
|
|
@ -11,6 +11,7 @@ use default_struct_builder::DefaultBuilder;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::watch_throttled;
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
@ -34,6 +35,7 @@ use default_struct_builder::DefaultBuilder;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::{watch_throttled_with_options, WatchThrottledOptions};
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
|
|
@ -17,6 +17,7 @@ use std::rc::Rc;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::{watch_with_options, WatchOptions};
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
@ -41,6 +42,7 @@ use std::rc::Rc;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::{watch_with_options, WatchOptions};
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
@ -59,6 +61,7 @@ use std::rc::Rc;
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::{watch_with_options, WatchOptions};
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
|
|
@ -6,6 +6,7 @@ use crate::{watch_with_options, WatchOptions};
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::whenever;
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
@ -23,6 +24,7 @@ use crate::{watch_with_options, WatchOptions};
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::whenever;
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
@ -41,6 +43,7 @@ use crate::{watch_with_options, WatchOptions};
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::whenever;
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
@ -60,6 +63,7 @@ use crate::{watch_with_options, WatchOptions};
|
|||
///
|
||||
/// ```
|
||||
/// # use leptos::*;
|
||||
/// # use leptos::logging::log;
|
||||
/// # use leptos_use::{WatchOptions, whenever_with_options};
|
||||
/// #
|
||||
/// # pub fn Demo() -> impl IntoView {
|
||||
|
|
Loading…
Add table
Reference in a new issue