xu-cheng / katex-rs Goto Github PK
View Code? Open in Web Editor NEWRust bindings to KaTeX
Home Page: https://docs.rs/katex
License: Apache License 2.0
Rust bindings to KaTeX
Home Page: https://docs.rs/katex
License: Apache License 2.0
I'm using the mdbook-katex preprocessor for mdbook with
output="mathml"
, not sure whether it's katex's fault or the rust binding to katex that mdbook-katex uses$$ \begin{aligned} e^x &= \sum_{n=0}^\infty \frac{x^n}{n!} \implies e^{ix} = \sum_{n=0}^\infty \frac{(ix)^n}{n!} \\ \cos x &= \sum_{m=0}^\infty \frac{(-1)^m x^{2m}}{(2m)!} = \sum_{m=0}^\infty \frac{(ix)^{2m}}{(2m)!} \\ \sin x &= \sum_{s=0}^\infty \frac{(-1)^s x^{2s+1}}{(2s+1)!} = \sum_{s=0}^\infty \frac{(ix)^{2s+1}}{i(2s+1)!} \\ \cos x + i\sin x &= \sum_{l=0}^\infty \frac{(ix)^{2l}}{(2l)!} + \sum_{s=0}^\infty \frac{(ix)^{2s+1}}{(2s+1)!} = \sum_{n=0}^\infty \frac{(ix)^{n}}{n!} \\ &= e^{ix} \end{aligned} $$
$$ \begin{aligned} e^x &= \sum_{n=0}^\infty \frac{x^n}{n!} \implies e^{ix} = \sum_{n=0}^\infty \frac{(ix)^n}{n!} \\ \cos x &= \sum_{m=0}^\infty \frac{(-1)^m x^{2m}}{(2m)!} = \sum_{m=0}^\infty \frac{(ix)^{2m}}{(2m)!} \\ \sin x &= \sum_{s=0}^\infty \frac{(-1)^s x^{2s+1}}{(2s+1)!} = \sum_{s=0}^\infty \frac{(ix)^{2s+1}}{i(2s+1)!} \\ \cos x + i\sin x &= \sum_{l=0}^\infty \frac{(ix)^{2l}}{(2l)!} + \sum_{s=0}^\infty \frac{(ix)^{2s+1}}{(2s+1)!} = \sum_{n=0}^\infty \frac{(ix)^{n}}{n!} \\ &= e^{ix} \end{aligned} $$ KaTeX-html
KaTeX-mathml
First of all, thanks for this great crate.
I am encountering an error when using this where Sync is also required.
Detailed stacktrace:
| impl ParseBlock for EquationBlock {
| ^^^^^^^^^^ `(dyn for<'r> std::ops::Fn(katex::TrustContext<'r>) -> bool + std::panic::RefUnwindSafe + 'static)` cannot be sent between threads safely
|
::: ~/.cargo/registry/src/github.com-1ecc6299db9ec823/liquid-core-0.21.2/src/parser/block.rs:32:30
|
32 | pub trait ParseBlock: Send + Sync + ParseBlockClone {
| ---- required by this bound in `liquid_core::parser::block::ParseBlock`
|
= help: the trait `std::marker::Send` is not implemented for `(dyn for<'r> std::ops::Fn(katex::TrustContext<'r>) -> bool + std::panic::RefUnwindSafe + 'static)`
= note: required because of the requirements on the impl of `std::marker::Sync` for `std::sync::Arc<(dyn for<'r> std::ops::Fn(katex::TrustContext<'r>) -> bool + std::panic::RefUnwindSafe + 'static)>`
= note: required because it appears within the type `katex::TrustCallback`
= note: required because it appears within the type `std::option::Option<katex::TrustCallback>`
= note: required because it appears within the type `katex::Opts`
= note: required because it appears within the type `equation_block::EquationBlock`
error[E0277]: `(dyn for<'r> std::ops::Fn(katex::TrustContext<'r>) -> bool + std::panic::RefUnwindSafe + 'static)` cannot be shared between threads safely
--> src/equation_block.rs:56:6
|
56 | impl ParseBlock for EquationBlock {
| ^^^^^^^^^^ `(dyn for<'r> std::ops::Fn(katex::TrustContext<'r>) -> bool + std::panic::RefUnwindSafe + 'static)` cannot be shared between threads safely
|
::: ~/.cargo/registry/src/github.com-1ecc6299db9ec823/liquid-core-0.21.2/src/parser/block.rs:32:30
|
32 | pub trait ParseBlock: Send + Sync + ParseBlockClone {
| ---- required by this bound in `liquid_core::parser::block::ParseBlock`
|
= help: the trait `std::marker::Sync` is not implemented for `(dyn for<'r> std::ops::Fn(katex::TrustContext<'r>) -> bool + std::panic::RefUnwindSafe + 'static)`
= note: required because of the requirements on the impl of `std::marker::Sync` for `std::sync::Arc<(dyn for<'r> std::ops::Fn(katex::TrustContext<'r>) -> bool + std::panic::RefUnwindSafe + 'static)>`
= note: required because it appears within the type `katex::TrustCallback`
= note: required because it appears within the type `std::option::Option<katex::TrustCallback>`
Hello,
Since the OptsBuilder
takes ownership of the macros
hashmap, the hashmap needs to be cloned every time a new equation is rendered.
I think it is a common use case to render multiple equations with the same set of macros / with the same opts. Wouldn't it be more convenient / faster to pass the macros as a &HashMap
reference?
Or, maybe even better, to pass an &Opts
reference to render_with_ops
?
Right now I have to clone macros
and create a new Opts
object every time I render a new equation. It looks like this
for item in items_to_render {
let cloned_macros = macros.clone();
let ops = katex::Opts::builder()
.display_mode(display)
.output_type(katex::OutputType::Html)
.macros(cloned_macros)
.build()
.unwrap();
let result = katex::render_with_opts(&item, ops);
...
}
Which could be replaced by
let ops = katex::Opts::builder()
.display_mode(display)
.output_type(katex::OutputType::Html)
.macros(macros)
.build()
.unwrap();
for item in items_to_render {
let result = katex::render_with_opts(&item, &ops);
...
}
Let me know if I'm missing something!
Simply adding
katex = { version = "0.4.5", default-features = false, features = ["wasm-js"] }
under [dependency]
of Cargo.toml
makes the build fail.
error[E0433]: failed to resolve: use of undeclared crate or module `js_sys`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:31:9
|
31 | js_sys::eval(code)
| ^^^^^^ use of undeclared crate or module `js_sys`
error[E0433]: failed to resolve: use of undeclared crate or module `js_sys`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:41:23
|
41 | let function: js_sys::Function = js_sys::Reflect::get(&js_sys::global(), &func_name.into())
| ^^^^^^ use of undeclared crate or module `js_sys`
error[E0433]: failed to resolve: use of undeclared crate or module `js_sys`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:41:42
|
41 | let function: js_sys::Function = js_sys::Reflect::get(&js_sys::global(), &func_name.into())
| ^^^^^^ use of undeclared crate or module `js_sys`
error[E0433]: failed to resolve: use of undeclared crate or module `js_sys`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:41:64
|
41 | let function: js_sys::Function = js_sys::Reflect::get(&js_sys::global(), &func_name.into())
| ^^^^^^ use of undeclared crate or module `js_sys`
error[E0433]: failed to resolve: use of undeclared crate or module `js_sys`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:45:19
|
45 | let args: js_sys::Array = args.map(|v| v.0).collect();
| ^^^^^^ use of undeclared crate or module `js_sys`
error[E0433]: failed to resolve: use of undeclared crate or module `wasm_bindgen`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:47:21
|
47 | .apply(&wasm_bindgen::JsValue::NULL, &args)
| ^^^^^^^^^^^^ use of undeclared crate or module `wasm_bindgen`
error[E0433]: failed to resolve: use of undeclared crate or module `js_sys`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:72:19
|
72 | let obj = js_sys::Object::new();
| ^^^^^^ use of undeclared crate or module `js_sys`
error[E0433]: failed to resolve: use of undeclared crate or module `js_sys`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:74:13
|
74 | js_sys::Reflect::set(&obj, &k.into(), &v.0)
| ^^^^^^ use of undeclared crate or module `js_sys`
error[E0433]: failed to resolve: use of undeclared crate or module `wasm_bindgen`
--> /Users/sichanghe/.cargo/registry/src/github.com-1ecc6299db9ec823/katex-0.4.5/src/js_engine/wasm_js.rs:83:18
|
83 | pub struct Value(wasm_bindgen::JsValue);
| ^^^^^^^^^^^^ use of undeclared crate or module `wasm_bindgen`
For more information about this error, try `rustc --explain E0433`.
error: could not compile `katex` due to 9 previous errors
Hi,
A small addition proposal: expose the katex version. This would help users to separately get the matching katex.css.min from upstream katex distributions.
It could be given to user via command line argument in pandoc-katex.
Thanks for pandoc-katex, it's great!
If I use katex
with:
katex = { version = "0.4.5", default-features = false, features = ["duktape"] }
then, matrix expressions like
\begin{vmatrix}a&b\\c&d\end{vmatrix}
results in an error:
JsExecError("undefined not callable (property 'fill' of [object Array]): JavaScript runtime error (TypeError)")
See this issue on mdbook-katex
for more.
When compiling code simply like this
fn main() {
let formula1 = katex::render("E = mc^2").unwrap();
let opts = katex::Opts::builder().display_mode(true).build().unwrap();
let formula2 = katex::render_with_opts("E = mc^2", opts).unwrap();
}
with command
cargo web build
Then it reports:
note: rust-lld: error: unknown file type: quickjs.nolto.o
This crate requires an embedded JS engine to execute katex. Currently, this is done using quickjs and its rust binding. However, it has certain shortages:
As such, we may want to find an alternative JS engine. Since this crate never exposes the types from the underlying JS engine, changing it will not create any breaking changes. Ideally, the alternatives need supporting all the current used features, addressing the above problems, being small to be embedded, and being well maintained.
Some candidates:
Testing katex in Windows CI failed though testing quick-js alone succeeded.
I am trying to fix the CI test of mdbook-katex.
Below is the log from testing a dummy crate with only katex
as its dependency:
error: failed to run custom build command for `libquickjs-sys v0.9.0`
Caused by:
process didn't exit successfully: `D:\a\mdbook-katex2\mdbook-katex2\target\debug\build\libquickjs-sys-3bf002dc4bca0895\build-script-build` (exit code: 101)
--- stdout
patching file libbf.c
--- stderr
Applying patches...
Applying "js-tobigint64-overflow.patch"...
Assertation failed!
Program: C:\Strawberry\c\bin\patch.exe
File: .\src\patch\2.5.9\patch-2.5.9-src\patch.c, Line 354
Expression: hunk
thread 'main' panicked at 'Patch command returned non-zero exit code', C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\libquickjs-sys-0.9.0\build.rs:136:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
Error: Process completed with exit code 1.
Since testing the dummy crate with only quick-js
and libquickjs-sys
succeeded, the above failure must have something to do with katex
. I cannot figure out what made the difference though.
Compiling libquickjs-sys v0.4.0
error: failed to run custom build command for `libquickjs-sys v0.4.0`
Caused by:
process didn't exit successfully: `D:\Rust\katex-rs\target\debug\build\libquickjs-sys-41555e9664b161d9\build-script-build` (exit code: 101)
--- stderr
Applying patches...
Applying "js-tobigint64-overflow.patch"...
thread 'main' panicked at 'Could not apply patches: Os { code: 2, kind: NotFound, message: "The system cannot find the file specified." }', C:\Users\Aster\.cargo\registry\src\github.com-1ecc6299db9ec823\libquickjs-sys-0.4.0\build.rs:100:22
stack backtrace:
0: backtrace::backtrace::trace_unsynchronized
at C:\Users\VssAdministrator\.cargo\registry\src\github.com-1ecc6299db9ec823\backtrace-0.3.44\src\backtrace\mod.rs:66
1: std::sys_common::backtrace::_print_fmt
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\sys_common\backtrace.rs:78
2: std::sys_common::backtrace::_print::{{impl}}::fmt
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\sys_common\backtrace.rs:59
3: core::fmt::write
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libcore\fmt\mod.rs:1052
4: std::io::Write::write_fmt<std::sys::windows::stdio::Stderr>
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\io\mod.rs:1428
5: std::sys_common::backtrace::_print
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\sys_common\backtrace.rs:62
6: std::sys_common::backtrace::print
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\sys_common\backtrace.rs:49
7: std::panicking::default_hook::{{closure}}
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\panicking.rs:204
8: std::panicking::default_hook
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\panicking.rs:224
9: std::panicking::rust_panic_with_hook
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\panicking.rs:470
10: std::panicking::begin_panic_handler
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\panicking.rs:378
11: core::panicking::panic_fmt
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libcore\panicking.rs:85
12: core::option::expect_none_failed
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libcore\option.rs:1211
13: core::result::Result<std::process::Child, std::io::error::Error>::expect<std::process::Child,std::io::error::Error>
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\src\libcore\result.rs:961
14: build_script_build::apply_patches
at .\build.rs:100
15: build_script_build::main
at .\build.rs:70
16: std::rt::lang_start::{{closure}}<()>
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\src\libstd\rt.rs:67
17: std::rt::lang_start_internal::{{closure}}
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\rt.rs:52
18: std::panicking::try::do_call<closure-0,i32>
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\panicking.rs:303
19: panic_unwind::__rust_maybe_catch_panic
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libpanic_unwind\lib.rs:86
20: std::panicking::try
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\panicking.rs:281
21: std::panic::catch_unwind
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\panic.rs:394
22: std::rt::lang_start_internal
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\/src\libstd\rt.rs:51
23: std::rt::lang_start<()>
at /rustc/433aae93e4ef866a1fdfefad136b32ed89acd3e7\src\libstd\rt.rs:67
24: main
25: invoke_main
at d:\agent\_work\3\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:78
26: __scrt_common_main_seh
at d:\agent\_work\3\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:288
27: BaseThreadInitThunk
28: RtlUserThreadStart
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
Process finished with exit code 101
When building katex
with feature duketape
, it shows errors:
2022-11-22T02:04:38.9353912Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:38.9421370Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:10:19
2022-11-22T02:04:38.9422561Z |
2022-11-22T02:04:38.9437607Z 10 | pub struct Engine(quick_js::Context);
2022-11-22T02:04:38.9438984Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.0179235Z
2022-11-22T02:04:39.0543945Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.0547748Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:19:26
2022-11-22T02:04:39.0548733Z |
2022-11-22T02:04:39.1729185Z 19 | pub struct Scope<'a>(&'a quick_js::Context);
2022-11-22T02:04:39.2224165Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.2531348Z
2022-11-22T02:04:39.4250294Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.4496254Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:68:18
2022-11-22T02:04:39.5536424Z |
2022-11-22T02:04:39.5537625Z 68 | pub struct Value(quick_js::JsValue);
2022-11-22T02:04:39.5538364Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.6139299Z
2022-11-22T02:04:39.6140093Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.6141092Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:76:11
2022-11-22T02:04:39.6141610Z |
2022-11-22T02:04:39.6142045Z 76 | impl From<quick_js::ContextError> for Error {
2022-11-22T02:04:39.6142476Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.6142745Z
2022-11-22T02:04:39.6143024Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.6144198Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:77:16
2022-11-22T02:04:39.6144707Z |
2022-11-22T02:04:39.6145161Z 77 | fn from(e: quick_js::ContextError) -> Self {
2022-11-22T02:04:39.6145618Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.6145916Z
2022-11-22T02:04:39.6146245Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.6146950Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:82:11
2022-11-22T02:04:39.6147549Z |
2022-11-22T02:04:39.6147896Z 82 | impl From<quick_js::ExecutionError> for Error {
2022-11-22T02:04:39.6148353Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.7221126Z
2022-11-22T02:04:39.7222947Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:39.7531691Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:83:16
2022-11-22T02:04:39.9249771Z |
2022-11-22T02:04:39.9562969Z 83 | fn from(e: quick_js::ExecutionError) -> Self {
2022-11-22T02:04:40.1283031Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.1945842Z
2022-11-22T02:04:40.1947213Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.1948352Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:88:11
2022-11-22T02:04:40.1949019Z |
2022-11-22T02:04:40.1949486Z 88 | impl From<quick_js::ValueError> for Error {
2022-11-22T02:04:40.1949981Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.1950343Z
2022-11-22T02:04:40.1950681Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.1951465Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:89:16
2022-11-22T02:04:40.1951960Z |
2022-11-22T02:04:40.1952462Z 89 | fn from(e: quick_js::ValueError) -> Self {
2022-11-22T02:04:40.1952952Z | ^^^^^^^^ use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.1953305Z
2022-11-22T02:04:40.1953653Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.2129040Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:14:27
2022-11-22T02:04:40.2129698Z |
2022-11-22T02:04:40.2130184Z 14 | Ok(Self(quick_js::Context::new()?))
2022-11-22T02:04:40.2130671Z | ^^^^^^^ not found in `quick_js`
2022-11-22T02:04:40.2131060Z |
2022-11-22T02:04:40.2131503Z help: consider importing one of these items
2022-11-22T02:04:40.2131955Z |
2022-11-22T02:04:40.2132374Z 3 | use core::task::Context;
2022-11-22T02:04:40.2132750Z |
2022-11-22T02:04:40.2133231Z 3 | use derive_builder::export::core::task::Context;
2022-11-22T02:04:40.2172127Z |
2022-11-22T02:04:40.2172713Z 3 | use std::task::Context;
2022-11-22T02:04:40.2173155Z |
2022-11-22T02:04:40.2173639Z help: if you import `Context`, refer to it directly
2022-11-22T02:04:40.2174049Z |
2022-11-22T02:04:40.2174891Z 14 - Ok(Self(quick_js::Context::new()?))
2022-11-22T02:04:40.2175350Z 14 + Ok(Self(Context::new()?))
2022-11-22T02:04:40.2175707Z |
2022-11-22T02:04:40.2175955Z
2022-11-22T02:04:40.2176235Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.2177034Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:42:28
2022-11-22T02:04:40.2177477Z |
2022-11-22T02:04:40.2177850Z 42 | Ok(Value(quick_js::JsValue::Bool(input)))
2022-11-22T02:04:40.2178274Z | ^^^^^^^ not found in `quick_js`
2022-11-22T02:04:40.2178892Z |
2022-11-22T02:04:40.2179246Z help: consider importing this trait
2022-11-22T02:04:40.2179597Z |
2022-11-22T02:04:40.2179928Z 3 | use crate::JsValue;
2022-11-22T02:04:40.2180226Z |
2022-11-22T02:04:40.2180594Z help: if you import `JsValue`, refer to it directly
2022-11-22T02:04:40.2180926Z |
2022-11-22T02:04:40.2181361Z 42 - Ok(Value(quick_js::JsValue::Bool(input)))
2022-11-22T02:04:40.2181762Z 42 + Ok(Value(JsValue::Bool(input)))
2022-11-22T02:04:40.2182109Z |
2022-11-22T02:04:40.2182421Z
2022-11-22T02:04:40.2182702Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.2183351Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:46:28
2022-11-22T02:04:40.2183817Z |
2022-11-22T02:04:40.2184181Z 46 | Ok(Value(quick_js::JsValue::Int(input)))
2022-11-22T02:04:40.2184866Z | ^^^^^^^ not found in `quick_js`
2022-11-22T02:04:40.2185191Z |
2022-11-22T02:04:40.2185548Z help: consider importing this trait
2022-11-22T02:04:40.2185884Z |
2022-11-22T02:04:40.2186173Z 3 | use crate::JsValue;
2022-11-22T02:04:40.2186509Z |
2022-11-22T02:04:40.2186882Z help: if you import `JsValue`, refer to it directly
2022-11-22T02:04:40.2187205Z |
2022-11-22T02:04:40.2187646Z 46 - Ok(Value(quick_js::JsValue::Int(input)))
2022-11-22T02:04:40.2188082Z 46 + Ok(Value(JsValue::Int(input)))
2022-11-22T02:04:40.2188432Z |
2022-11-22T02:04:40.2188630Z
2022-11-22T02:04:40.2188889Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.2189550Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:50:28
2022-11-22T02:04:40.2190008Z |
2022-11-22T02:04:40.2190352Z 50 | Ok(Value(quick_js::JsValue::Float(input)))
2022-11-22T02:04:40.2190740Z | ^^^^^^^ not found in `quick_js`
2022-11-22T02:04:40.2196675Z |
2022-11-22T02:04:40.2197099Z help: consider importing this trait
2022-11-22T02:04:40.2197425Z |
2022-11-22T02:04:40.2197736Z 3 | use crate::JsValue;
2022-11-22T02:04:40.2198018Z |
2022-11-22T02:04:40.2198384Z help: if you import `JsValue`, refer to it directly
2022-11-22T02:04:40.2198757Z |
2022-11-22T02:04:40.2199342Z 50 - Ok(Value(quick_js::JsValue::Float(input)))
2022-11-22T02:04:40.2199727Z 50 + Ok(Value(JsValue::Float(input)))
2022-11-22T02:04:40.2200959Z |
2022-11-22T02:04:40.2202001Z
2022-11-22T02:04:40.2202682Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.2533064Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:54:28
2022-11-22T02:04:40.3446651Z |
2022-11-22T02:04:40.3448083Z 54 | Ok(Value(quick_js::JsValue::String(input)))
2022-11-22T02:04:40.3448974Z | ^^^^^^^ not found in `quick_js`
2022-11-22T02:04:40.4099018Z |
2022-11-22T02:04:40.5358785Z help: consider importing this trait
2022-11-22T02:04:40.6130455Z |
2022-11-22T02:04:40.7380834Z 3 | use crate::JsValue;
2022-11-22T02:04:40.7494638Z |
2022-11-22T02:04:40.7619511Z help: if you import `JsValue`, refer to it directly
2022-11-22T02:04:40.8736222Z |
2022-11-22T02:04:40.8738303Z 54 - Ok(Value(quick_js::JsValue::String(input)))
2022-11-22T02:04:40.8739121Z 54 + Ok(Value(JsValue::String(input)))
2022-11-22T02:04:40.9411919Z |
2022-11-22T02:04:40.9449794Z
2022-11-22T02:04:40.9450915Z error[E0433]: failed to resolve: use of undeclared crate or module `quick_js`
2022-11-22T02:04:40.9452021Z --> C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\katex-0.4.5\src\js_engine\quick_js.rs:62:28
2022-11-22T02:04:40.9452620Z |
2022-11-22T02:04:40.9453098Z 62 | Ok(Value(quick_js::JsValue::Object(obj)))
2022-11-22T02:04:40.9453994Z | ^^^^^^^ not found in `quick_js`
2022-11-22T02:04:40.9454447Z |
2022-11-22T02:04:40.9454891Z help: consider importing this trait
2022-11-22T02:04:41.0664135Z |
2022-11-22T02:04:41.0725223Z 3 | use crate::JsValue;
2022-11-22T02:04:41.0726331Z |
2022-11-22T02:04:41.0727137Z help: if you import `JsValue`, refer to it directly
2022-11-22T02:04:41.2698173Z |
2022-11-22T02:04:41.3118209Z 62 - Ok(Value(quick_js::JsValue::Object(obj)))
2022-11-22T02:04:41.3119524Z 62 + Ok(Value(JsValue::Object(obj)))
2022-11-22T02:04:41.3120350Z |
2022-11-22T02:04:41.3120678Z
2022-11-22T02:04:41.3121298Z For more information about this error, try `rustc --explain E0433`.
2022-11-22T02:04:41.3121906Z error: could not compile `katex` due to 15 previous errors
2022-11-22T02:04:41.3122429Z warning: build failed, waiting for other jobs to finish...
2022-11-22T02:04:42.7741958Z ##[error]Process completed with exit code 1.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.