pub fn view_with_unreactive_state<F, S>(mut self, val: F) -> Self
    where
        F: Fn(Scope, S, P) -> View<G> + Clone + Send + Sync + 'static,
        S: MakeRx + Serialize + DeserializeOwned + UnreactiveState + 'static,
        <S as MakeRx>::Rx: AnyFreeze + Clone + MakeUnrx<Unrx = S>,
    {
        self.template_inner.view =
            Box::new(|_, _, _, _| panic!("attempted to call template rendering logic for widget"));
        #[cfg(any(client, doc))]
        let entity_name = self.template_inner.get_path();
        #[cfg(any(client, doc))]
        let fallback_fn = self.fallback.clone(); // `Arc`ed, heaven help us
        self.capsule_view = Box::new(
            #[allow(unused_variables)]
            move |app_cx, preload_info, template_state, props, path, caller_path| {
                let reactor = Reactor::<G>::from_cx(app_cx);
                reactor.get_unreactive_widget_view(
                    app_cx,
                    path,
                    caller_path,
                    #[cfg(any(client, doc))]
                    entity_name.clone(),
                    template_state,
                    props,
                    #[cfg(any(client, doc))]
                    preload_info,
                    val.clone(),
                    #[cfg(any(client, doc))]
                    fallback_fn.as_ref().unwrap(),
                )
            },
        );
        self
    }
Sets the rendering function to use for capsules that take unreactive
state.
packages/perseus/src/template/capsule.rs