File tree Expand file tree Collapse file tree 4 files changed +18
-8
lines changed
Expand file tree Collapse file tree 4 files changed +18
-8
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ version = "0.1.0"
44edition = " 2021"
55
66[dependencies ]
7- dioxus = { workspace = true , features = [{{- router_feature -}}] }
7+ dioxus = { workspace = true , features = [{{- dioxus_features -}}] }
88ui = { workspace = true }
99
1010[features]
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ version = "0.1.0"
44edition = " 2021"
55
66[dependencies ]
7- dioxus = { workspace = true , features = [{{- router_feature -}}] }
7+ dioxus = { workspace = true , features = [{{- dioxus_features -}}] }
88ui = { workspace = true }
99
1010[features]
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ version = "0.1.0"
44edition = " 2021"
55
66[dependencies ]
7- dioxus = { workspace = true , features = [{{- router_feature -}}] }
7+ dioxus = { workspace = true , features = [{{- dioxus_features -}}] }
88ui = { workspace = true }
99
1010[features]
Original file line number Diff line number Diff line change 11// This file sets variables based on the results of the shared-init script.
22
33const WORKSPACE_MEMBERS_VAR = "workspace_members";
4- const ROUTER_FEATURE_VAR = "router_feature ";
4+ const DIOXUS_FEATURE_VAR = "dioxus_features ";
55
66const IS_FULLSTACK = "is_fullstack";
77const IS_ROUTER = "is_router";
@@ -14,9 +14,19 @@ if variable::get(IS_FULLSTACK) {
1414
1515variable::set(WORKSPACE_MEMBERS_VAR, workspace_members);
1616
17- // Router feature
17+ // Dioxus features
18+ let features = [];
1819if variable::get(IS_ROUTER) {
19- variable::set(ROUTER_FEATURE_VAR, "\"router\"");
20- } else {
21- variable::set(ROUTER_FEATURE_VAR, "");
20+ features.push("router");
2221}
22+ if variable::get(IS_FULLSTACK) {
23+ features.push("fullstack");
24+ }
25+ let features_string = "";
26+ for feature in features {
27+ if features_string.len() > 0 {
28+ features_string += ", ";
29+ }
30+ features_string += "\"" + feature + "\"";
31+ }
32+ variable::set(DIOXUS_FEATURE_VAR, features_string);
You can’t perform that action at this time.
0 commit comments