Skip to content

Commit b8549ed

Browse files
authored
Merge branch 'main' into managing_state_graph
2 parents 3972b69 + e5ab210 commit b8549ed

File tree

76 files changed

+1147
-704
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+1147
-704
lines changed

.github/workflows/check.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@ on:
66
- main
77
paths:
88
- examples/**
9-
- docs_src/**
10-
- src/**
9+
- docs-src/**
10+
- packages/**/*.rs
11+
- packages/**/Cargo.toml
1112
- .github/**
1213
- lib.rs
1314
- Cargo.toml
@@ -18,8 +19,9 @@ on:
1819
- main
1920
paths:
2021
- examples/**
21-
- docs_src/**
22-
- src/**
22+
- docs-src/**
23+
- packages/**/*.rs
24+
- packages/**/Cargo.toml
2325
- .github/**
2426
- lib.rs
2527
- Cargo.toml

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
!.vscode/extensions.json
1010

1111
.idea
12+
.env
1213

1314
/pkg
1415
/static

.vscode/settings.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@
66
"[css]": {
77
"editor.formatOnSave": false
88
},
9-
"rust-analyzer.cargo.features": [
10-
"web",
11-
"server"
12-
],
139
"cSpell.words": [
1410
"appimage",
1511
"autoplay",

Cargo.lock

Lines changed: 57 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,9 @@ serde_json = "1.0.133"
6868
futures = "0.3.30"
6969
uuid = "1.8.0"
7070
gloo-net = { version = "0.6.0", features = ["websocket"] }
71+
gloo-utils = "0.2.0"
7172
axum = { version = "0.7.5" }
73+
reqwest = { version = "0.12.12" }
7274
thiserror = "2.0.4"
7375
yazi = "0.2.1"
7476
chrono = { version = "0.4.39" }

Dioxus.toml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
11
[application]
22
name = "docsite"
3-
4-
[web.app]
5-
base_path = "docsite"

Dockerfile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,15 @@ COPY --from=builder /app/target/release/server /usr/src/app/server
3838
COPY --from=builder /app/packages/playground/server/template /usr/src/app/template
3939
COPY --from=planner /.cargo/bin/dx /usr/local/bin
4040

41+
# Setup environment
4142
RUN mkdir /usr/src/app/temp
4243
ENV PATH="${PATH}:/usr/local/bin"
4344
ENV PORT=8080
44-
env PRODUCTION=true
45+
ENV PRODUCTION=true
4546
ENV BUILD_TEMPLATE_PATH="/usr/src/app/template"
4647
EXPOSE 8080
4748

49+
# Prebuild examples + target cache
50+
RUN /usr/src/app/server --prebuild
51+
4852
ENTRYPOINT [ "/usr/src/app/server" ]

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ With [`dx`][dx] installed, you can use it to build and serve the documentation
2626
on your local system:
2727

2828
```sh
29-
dx serve
29+
dx serve --package dioxus_docs_site
3030
```
3131

3232
This will start a local server that will be available on

docs-src/0.5/src/cookbook/state/custom_hooks/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@ Inside the initialization closure, you will typically make calls to other `cx` m
3535
Here is a simplified implementation of the `use_signal` hook:
3636

3737
```rust
38-
{{#include src/doc_examples/hooks_custom_logic.rs:use_signal}}
38+
{{#include src/doc_examples/untested_05/hooks_custom_logic.rs:use_signal}}
3939
```
4040

4141
- The `use_context` hook calls [`consume_context`](https://docs.rs/dioxus/latest/dioxus/prelude/fn.consume_context.html) (which would be expensive to call on every render) to get some context from the component
4242

4343
Here is an implementation of the `use_context` and `use_context_provider` hooks:
4444

4545
```rust
46-
{{#include src/doc_examples/hooks_custom_logic.rs:use_context}}
46+
{{#include src/doc_examples/untested_05/hooks_custom_logic.rs:use_context}}
4747
```

docs-src/0.5/zh/cookbook/state/custom_hooks/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@ Inside the initialization closure, you will typically make calls to other `cx` m
3535
Here is a simplified implementation of the `use_signal` hook:
3636

3737
\```rust
38-
{{#include src/doc_examples/hooks_custom_logic.rs:use_signal}}
38+
{{#include src/doc_examples/untested_05/hooks_custom_logic.rs:use_signal}}
3939
\```
4040

4141
- The `use_context` hook calls [`consume_context`](https://docs.rs/dioxus/latest/dioxus/prelude/fn.consume_context.html) (which would be expensive to call on every render) to get some context from the component
4242

4343
Here is an implementation of the `use_context` and `use_context_provider` hooks:
4444

4545
\```rust
46-
{{#include src/doc_examples/hooks_custom_logic.rs:use_context}}
46+
{{#include src/doc_examples/untested_05/hooks_custom_logic.rs:use_context}}
4747
\```

0 commit comments

Comments
 (0)