diff --git a/.idea/leptos-use.iml b/.idea/leptos-use.iml
index 201a77c..a753bb6 100644
--- a/.idea/leptos-use.iml
+++ b/.idea/leptos-use.iml
@@ -11,12 +11,14 @@
+
+
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 295292c..047d98b 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,4 +2,9 @@
## 0.1.3
-- Added `use_scroll`.
\ No newline at end of file
+#### New Functions
+- `use_scroll`
+- `use_debounce_fn`
+
+#### Other Changes
+- Better and more beautiful demo integration into the guide.
\ No newline at end of file
diff --git a/docs/book/src/SUMMARY.md b/docs/book/src/SUMMARY.md
index 6afe548..57c0c9b 100644
--- a/docs/book/src/SUMMARY.md
+++ b/docs/book/src/SUMMARY.md
@@ -1,6 +1,7 @@
# Summary
[Introduction]()
+[Changelog](changelog.md)
# Getting Started
@@ -13,4 +14,5 @@
# Utilities
+- [use_debounce_fn](utilities/use_debounce_fn.md)
- [use_throttle_fn](utilities/use_throttle_fn.md)
\ No newline at end of file
diff --git a/docs/book/src/changelog.md b/docs/book/src/changelog.md
new file mode 100644
index 0000000..29f8b6a
--- /dev/null
+++ b/docs/book/src/changelog.md
@@ -0,0 +1 @@
+{{#include ../../../CHANGELOG.md}}
\ No newline at end of file
diff --git a/docs/book/src/utilities/use_debounce_fn.md b/docs/book/src/utilities/use_debounce_fn.md
new file mode 100644
index 0000000..bcd5ec8
--- /dev/null
+++ b/docs/book/src/utilities/use_debounce_fn.md
@@ -0,0 +1,3 @@
+# use_debounce_fn
+
+
diff --git a/examples/use_debounce_fn/Cargo.toml b/examples/use_debounce_fn/Cargo.toml
new file mode 100644
index 0000000..df49a7a
--- /dev/null
+++ b/examples/use_debounce_fn/Cargo.toml
@@ -0,0 +1,16 @@
+[package]
+name = "use_debounce_fn"
+version = "0.1.0"
+edition = "2021"
+
+[dependencies]
+leptos = "0.3"
+console_error_panic_hook = "0.1"
+console_log = "1"
+log = "0.4"
+leptos-use = { path = "../.." }
+web-sys = "0.3"
+
+[dev-dependencies]
+wasm-bindgen = "0.2"
+wasm-bindgen-test = "0.3.0"
diff --git a/examples/use_debounce_fn/README.md b/examples/use_debounce_fn/README.md
new file mode 100644
index 0000000..6d5ce15
--- /dev/null
+++ b/examples/use_debounce_fn/README.md
@@ -0,0 +1,16 @@
+A simple example for `use_debounce_fn`.
+
+If you don't have it installed already, install [Trunk](https://trunkrs.dev/)
+as well as the nightly toolchain for Rust and the wasm32-unknown-unknown target:
+
+```bash
+cargo install trunk
+rustup toolchain install nightly
+rustup target add wasm32-unknown-unknown
+```
+
+To run the demo:
+
+```bash
+trunk serve --open
+```
diff --git a/examples/use_debounce_fn/Trunk.toml b/examples/use_debounce_fn/Trunk.toml
new file mode 100644
index 0000000..f521021
--- /dev/null
+++ b/examples/use_debounce_fn/Trunk.toml
@@ -0,0 +1,2 @@
+[build]
+public_url = "./demo/"
\ No newline at end of file
diff --git a/examples/use_debounce_fn/index.html b/examples/use_debounce_fn/index.html
new file mode 100644
index 0000000..25f83eb
--- /dev/null
+++ b/examples/use_debounce_fn/index.html
@@ -0,0 +1,5 @@
+
+
+
+
+
diff --git a/examples/use_debounce_fn/rust-toolchain.toml b/examples/use_debounce_fn/rust-toolchain.toml
new file mode 100644
index 0000000..271800c
--- /dev/null
+++ b/examples/use_debounce_fn/rust-toolchain.toml
@@ -0,0 +1,2 @@
+[toolchain]
+channel = "nightly"
\ No newline at end of file
diff --git a/examples/use_debounce_fn/src/main.rs b/examples/use_debounce_fn/src/main.rs
new file mode 100644
index 0000000..6801092
--- /dev/null
+++ b/examples/use_debounce_fn/src/main.rs
@@ -0,0 +1,40 @@
+use leptos::*;
+use leptos_use::use_debounce_fn_with_options;
+use leptos_use::utils::{demo_or_body, DebounceOptions};
+
+#[component]
+fn Demo(cx: Scope) -> impl IntoView {
+ let (click_count, set_click_count) = create_signal(cx, 0);
+ let (debounced_count, set_debounced_count) = create_signal(cx, 0);
+
+ let debounced_fn = use_debounce_fn_with_options(
+ move || set_debounced_count(debounced_count() + 1),
+ 1000.0,
+ DebounceOptions {
+ max_wait: Some(5000.0),
+ },
+ );
+
+ view! { cx,
+
+ "Delay is set to 1000ms and max_wait is set to 5000ms for this demo."
+ "Button clicked: " { click_count }
+ "Event handler called: " { debounced_count }
+ }
+}
+
+fn main() {
+ _ = console_log::init_with_level(log::Level::Debug);
+ console_error_panic_hook::set_once();
+
+ mount_to(demo_or_body(), |cx| {
+ view! { cx, }
+ })
+}
diff --git a/examples/use_throttle_fn/src/main.rs b/examples/use_throttle_fn/src/main.rs
index 6aeab76..1db6efc 100644
--- a/examples/use_throttle_fn/src/main.rs
+++ b/examples/use_throttle_fn/src/main.rs
@@ -7,8 +7,7 @@ fn Demo(cx: Scope) -> impl IntoView {
let (click_count, set_click_count) = create_signal(cx, 0);
let (throttled_count, set_throttled_count) = create_signal(cx, 0);
- let mut throttled_fn =
- use_throttle_fn(move || set_throttled_count(throttled_count() + 1), 1000.0);
+ let throttled_fn = use_throttle_fn(move || set_throttled_count(throttled_count() + 1), 1000.0);
view! { cx,