Cleaned dead code and updated documents
This commit is contained in:
@@ -8,7 +8,6 @@
|
||||
use std::path::PathBuf;
|
||||
|
||||
use askama::Template;
|
||||
use indexmap::IndexMap;
|
||||
|
||||
use crate::config::Config;
|
||||
use crate::emit::CodegenTarget;
|
||||
|
||||
@@ -26,7 +26,7 @@ import {
|
||||
{% if has_contexts -%}
|
||||
registerContext,
|
||||
type ContextState,
|
||||
{% endif -%}
|
||||
{% endif -%}
|
||||
} from '@mizan/base'
|
||||
|
||||
{% if !stage1_imports.is_empty() -%}
|
||||
|
||||
@@ -18,7 +18,7 @@ fn fixture_config() -> Config {
|
||||
project_id: None,
|
||||
output: PathBuf::from("/tmp"),
|
||||
targets: vec!["channels".to_string()],
|
||||
source: SourceConfig { fastapi: None, django: None },
|
||||
source: SourceConfig { fastapi: None, django: None, rust: None, script: None },
|
||||
rust_kernel: None,
|
||||
rust_crate_name: None,
|
||||
}
|
||||
|
||||
@@ -14,10 +14,8 @@ import {
|
||||
} from 'react'
|
||||
import {
|
||||
configure,
|
||||
initSession,
|
||||
mizanCall,
|
||||
mizanFetch,
|
||||
MizanError,
|
||||
registerContext,
|
||||
type ContextState,
|
||||
} from '@mizan/base'
|
||||
@@ -45,6 +43,7 @@ function useContextSubscription<T>(
|
||||
return useSyncExternalStore(handle.subscribe, handle.getState, handle.getState)
|
||||
}
|
||||
|
||||
|
||||
// Internal — wraps an imperative call() with isPending / error state.
|
||||
interface MutationHook<TArgs, TResult> {
|
||||
mutate: (args: TArgs) => Promise<TResult>
|
||||
|
||||
@@ -20,7 +20,7 @@ fn fixture_config() -> Config {
|
||||
project_id: None,
|
||||
output: PathBuf::from("/tmp"),
|
||||
targets: vec!["python".to_string()],
|
||||
source: SourceConfig { fastapi: None, django: None },
|
||||
source: SourceConfig { fastapi: None, django: None, rust: None, script: None },
|
||||
rust_kernel: None,
|
||||
rust_crate_name: None,
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ fn fixture_config() -> Config {
|
||||
project_id: None,
|
||||
output: PathBuf::from("/tmp"),
|
||||
targets: vec!["react".to_string()],
|
||||
source: SourceConfig { fastapi: None, django: None },
|
||||
source: SourceConfig { fastapi: None, django: None, rust: None, script: None },
|
||||
rust_kernel: None,
|
||||
rust_crate_name: None,
|
||||
}
|
||||
|
||||
@@ -24,7 +24,7 @@ fn fixture_config() -> Config {
|
||||
project_id: None,
|
||||
output: PathBuf::from("/tmp"),
|
||||
targets: vec!["rust".to_string()],
|
||||
source: SourceConfig { fastapi: None, django: None },
|
||||
source: SourceConfig { fastapi: None, django: None, rust: None, script: None },
|
||||
rust_kernel: Some(RustKernelSpec::Path {
|
||||
path: "../../../frontends/mizan-rust".to_string(),
|
||||
}),
|
||||
|
||||
@@ -30,7 +30,7 @@ fn synthetic_config() -> Config {
|
||||
project_id: None,
|
||||
output: PathBuf::from("/tmp"),
|
||||
targets: vec!["stage1".to_string()],
|
||||
source: SourceConfig { fastapi: None, django: None },
|
||||
source: SourceConfig { fastapi: None, django: None, rust: None, script: None },
|
||||
rust_kernel: None,
|
||||
rust_crate_name: None,
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ fn fixture_config(target: &str) -> Config {
|
||||
project_id: None,
|
||||
output: PathBuf::from("/tmp"),
|
||||
targets: vec![target.to_string()],
|
||||
source: SourceConfig { fastapi: None, django: None },
|
||||
source: SourceConfig { fastapi: None, django: None, rust: None, script: None },
|
||||
rust_kernel: None,
|
||||
rust_crate_name: None,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user