Migrate project to workspace
This commit is contained in:
parent
922573ff65
commit
fe9c97bb19
20
Cargo.toml
20
Cargo.toml
@ -1,16 +1,6 @@
|
||||
[package]
|
||||
name = "jana_sessions_webpage"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
[workspace]
|
||||
resolver = "2"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
default-run = "jana_sessions_webpage"
|
||||
|
||||
[dependencies]
|
||||
chrono = { version = "0.4", features = ["serde"] }
|
||||
leptos = { version = "0.7", features = ["csr"] }
|
||||
console_error_panic_hook = "0.1.7"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
clap = { version = "4.5", features = ["derive"] }
|
||||
members = [
|
||||
"leptos_webpage",
|
||||
]
|
||||
|
||||
32
README.md
32
README.md
@ -1,32 +1,10 @@
|
||||
# Jana Sessions Webpage
|
||||
|
||||
The webpage for Jana-Sessions (unofficial name), fully written in Rust.
|
||||
The webpage of Jana Sessions (unofficial name) written in Rust.
|
||||
|
||||
## Building
|
||||
The project currently consists of only a single crate, but a mayor refactoring is planned.
|
||||
|
||||
The project currently uses leptos, so you'll want to install trunk (`cargo install trunk`).
|
||||
For the build to work you'll need the `wasm32-unknown-unknown` target (`rustup target add wasm32-unknown-unknown`).
|
||||
|
||||
You can build the projekt with
|
||||
```bash
|
||||
trunk build --release
|
||||
```
|
||||
which will create the app in the `target/dist` folder.
|
||||
|
||||
Alternatively you can serve it locally with
|
||||
```bash
|
||||
trunk serve
|
||||
```
|
||||
|
||||
To also access the local hosted page from other devices, use
|
||||
```bash
|
||||
trunk serve -a 0.0.0.0
|
||||
```
|
||||
|
||||
## Deployment
|
||||
|
||||
Just use pythons webserver and point it to the dist folder
|
||||
```bash
|
||||
python3 -m http.server 8080 --directoy target/dist
|
||||
```
|
||||
## leptos_webpage
|
||||
|
||||
The first functional version of the page, using leptos and trunk.
|
||||
Please see the README there for more details.
|
||||
16
leptos_webpage/Cargo.toml
Normal file
16
leptos_webpage/Cargo.toml
Normal file
@ -0,0 +1,16 @@
|
||||
[package]
|
||||
name = "jana_sessions_webpage"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
default-run = "jana_sessions_webpage"
|
||||
|
||||
[dependencies]
|
||||
chrono = { version = "0.4", features = ["serde"] }
|
||||
leptos = { version = "0.7", features = ["csr"] }
|
||||
console_error_panic_hook = "0.1.7"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
clap = { version = "4.5", features = ["derive"] }
|
||||
32
leptos_webpage/README.md
Normal file
32
leptos_webpage/README.md
Normal file
@ -0,0 +1,32 @@
|
||||
# Jana Sessions Webpage
|
||||
|
||||
The webpage for Jana-Sessions (unofficial name), fully written in Rust.
|
||||
|
||||
## Building
|
||||
|
||||
The project currently uses leptos, so you'll want to install trunk (`cargo install trunk`).
|
||||
For the build to work you'll need the `wasm32-unknown-unknown` target (`rustup target add wasm32-unknown-unknown`).
|
||||
|
||||
You can build the projekt with
|
||||
```bash
|
||||
trunk build --release
|
||||
```
|
||||
which will create the app in the `target/dist` folder.
|
||||
|
||||
Alternatively you can serve it locally with
|
||||
```bash
|
||||
trunk serve
|
||||
```
|
||||
|
||||
To also access the local hosted page from other devices, use
|
||||
```bash
|
||||
trunk serve -a 0.0.0.0
|
||||
```
|
||||
|
||||
## Deployment
|
||||
|
||||
Just use pythons webserver and point it to the dist folder
|
||||
```bash
|
||||
python3 -m http.server 8080 --directoy target/dist
|
||||
```
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
[build]
|
||||
filehash = false
|
||||
dist = "target/dist"
|
||||
dist = "../target/dist"
|
||||
public_url = "."
|
||||
|
||||
[[hooks]]
|
||||
Loading…
Reference in New Issue
Block a user