如何输入/排版化学反应方程式?
使用这个包:https://github.com/schang412/typst-whalogen
typst
#import "@preview/whalogen:0.2.0": ce
$ #ce("HCl + H2O -> H3O+ + Cl-") $

log
warning: comparing strings with types is deprecated
┌─ @preview/whalogen:0.2.0/lib.typ:187:9
│
187 │ assert(type(t) == "string", message: "ce: argument must be of type `string`")
│ ^^^^^^^^^^^^^^^^^^^
│
= hint: compare with the literal type instead
= hint: this comparison will always return `false` in future Typst releases
warning: comparing strings with types is deprecated
┌─ @preview/whalogen:0.2.0/lib.typ:162:9
│
162 │ if type(r) != "string" {
│ ^^^^^^^^^^^^^^^^^^^
│
= hint: compare with the literal type instead
= hint: this comparison will always return `false` in future Typst releases
warning: comparing strings with types is deprecated
┌─ @preview/whalogen:0.2.0/lib.typ:12:7
│
12 │ if type(item) != "string" {
│ ^^^^^^^^^^^^^^^^^^^^^^
│
= hint: compare with the literal type instead
= hint: this comparison will always return `false` in future Typst releases
warning: this return unconditionally discards the content before it
┌─ @preview/whalogen:0.2.0/lib.typ:22:2
│
22 │ return result
│ ^^^^^^^^^^^^^
│
= hint: try omitting the `return` to automatically join all values
warning: comparing strings with types is deprecated
┌─ @preview/whalogen:0.2.0/lib.typ:210:7
│
210 │ if type(result_sub_str) == "string" {
│ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
│
= hint: compare with the literal type instead
= hint: this comparison will always return `false` in future Typst releases
warning: comparing strings with types is deprecated
┌─ @preview/whalogen:0.2.0/lib.typ:213:14
│
213 │ } else if type(result_sub_str) == "content" {
│ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
│
= hint: compare with the literal type instead
= hint: this comparison will always return `false` in future Typst releases