Make work
This commit is contained in:
parent
efeb2d56dc
commit
3b0eb7fc1c
@ -15,9 +15,5 @@ actix-web-actors = "3.0.0"
|
||||
rust-embed="6.0.0"
|
||||
hex = "0.4.3"
|
||||
serde_json = "1"
|
||||
# actix-web-static-files = "3.0"
|
||||
live-view = { path = "./liveview-rust/" }
|
||||
askama = "0.10.5"
|
||||
|
||||
[build-dependencies]
|
||||
actix-web-static-files = "3.0"
|
||||
|
@ -13,12 +13,9 @@ use actix_web::{
|
||||
web::JsonConfig,
|
||||
App, HttpServer, Responder, Result,
|
||||
};
|
||||
// use actix_web_static_files::ResourceFiles;
|
||||
use std::io;
|
||||
use std::sync::{mpsc::Sender, Arc, Mutex};
|
||||
|
||||
// include!(concat!(env!("OUT_DIR"), "/generated.rs"));
|
||||
|
||||
struct AppState {
|
||||
strip_tx: Arc<Mutex<Sender<strip::Message>>>,
|
||||
}
|
||||
@ -44,7 +41,6 @@ pub async fn start(
|
||||
) -> std::io::Result<()> {
|
||||
let _ = message_tx.send(errors::Message::String(String::from("Starting webui")));
|
||||
HttpServer::new(move || {
|
||||
// let generated = generate();
|
||||
App::new()
|
||||
.data(AppState {
|
||||
strip_tx: Arc::new(Mutex::new(strip_tx.clone())),
|
||||
@ -68,7 +64,6 @@ pub async fn start(
|
||||
)
|
||||
.service(web::resource("/ws/").route(web::get().to(start_socket)))
|
||||
.service(initial_load)
|
||||
// .service(ResourceFiles::new("/", generated))
|
||||
})
|
||||
.bind(("0.0.0.0", 8080))?
|
||||
.run()
|
||||
|
@ -1,3 +1,11 @@
|
||||
In control
|
||||
{{ count }}
|
||||
<button rust-click="inc">Inc</button>
|
||||
{% match 'a' %}
|
||||
{% when 'a' %}
|
||||
Found literal a
|
||||
{% when 'b' %}
|
||||
Found literal b
|
||||
{% else %}
|
||||
Else found nothing
|
||||
{% endmatch %}
|
||||
|
Loading…
Reference in New Issue
Block a user