texcreate_lib 0.1.17

The core library for texcreate
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18

use rocket::{get, routes};
use rocket::fs::NamedFile;
use std::path::Path;
use rocket::{Rocket, Build};
use crate::Web::tex_create;


#[get("/")]
pub async fn index() -> Option<NamedFile>{
    let index = Path::new("texcreate.html");
    NamedFile::open("texcreate.html").await.ok()
}

pub fn texweb() -> Rocket<Build> {
    rocket::build()
    .mount("/", routes![index, tex_create])
}