From 1fc165f2a5a3b6d77da2cfea2aa05e1db1c73577 Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Sun, 5 Oct 2025 18:27:05 +0200 Subject: feat(form): Re-write the form macro as a proc macro This allows more possibilities. --- src/components/input_placeholder.rs | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'src/components/input_placeholder.rs') diff --git a/src/components/input_placeholder.rs b/src/components/input_placeholder.rs index 05b9509..aeef838 100644 --- a/src/components/input_placeholder.rs +++ b/src/components/input_placeholder.rs @@ -1,5 +1,3 @@ -use std::sync::atomic::{AtomicU32, Ordering}; - use leptos::{ IntoView, component, html::Input, @@ -7,11 +5,8 @@ use leptos::{ view, }; -fn get_id() -> u32 { - static ID: AtomicU32 = AtomicU32::new(0); +use crate::components::get_id; - ID.fetch_add(1, Ordering::Relaxed) -} #[component] pub fn InputPlaceholder( -- cgit 1.4.1