separate markdown files, unbloat rocket
This commit is contained in:
parent
67f26fe5f5
commit
78200d2890
4 changed files with 4 additions and 7 deletions
|
@ -6,7 +6,7 @@ edition = "2021"
|
||||||
[dependencies]
|
[dependencies]
|
||||||
amplify = "4.8.0"
|
amplify = "4.8.0"
|
||||||
md = {version = "1.0.0-alpha.21", package = "markdown"}
|
md = {version = "1.0.0-alpha.21", package = "markdown"}
|
||||||
rocket = "0"
|
rocket = {version="0", default-features = false}
|
||||||
shuttle-rocket = "*"
|
shuttle-rocket = "*"
|
||||||
shuttle-runtime = "*"
|
shuttle-runtime = "*"
|
||||||
tokio = "1"
|
tokio = "1"
|
||||||
|
|
|
@ -1,10 +1,6 @@
|
||||||
name = "typonomy"
|
name = "typonomy"
|
||||||
[deploy]
|
|
||||||
include = [
|
|
||||||
"dist/*",
|
|
||||||
]
|
|
||||||
|
|
||||||
[build]
|
[build]
|
||||||
assets = [
|
assets = [
|
||||||
"dist/*",
|
"static/*",
|
||||||
]
|
]
|
||||||
|
|
|
@ -5,7 +5,7 @@ use markdown::{Markdown, MarkdownConvertError};
|
||||||
|
|
||||||
#[get("/")]
|
#[get("/")]
|
||||||
fn index() -> Result<Markdown, MarkdownConvertError> {
|
fn index() -> Result<Markdown, MarkdownConvertError> {
|
||||||
"<h1>Hello, world!</h1>".parse()
|
include_str!("../static/hello-world.md").parse()
|
||||||
}
|
}
|
||||||
|
|
||||||
#[shuttle_runtime::main]
|
#[shuttle_runtime::main]
|
||||||
|
|
1
static/hello-world.md
Normal file
1
static/hello-world.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
<h1>Hello, world!</h1>
|
Loading…
Reference in a new issue