Skip to content
This repository has been archived by the owner on Jun 6, 2023. It is now read-only.

Limitations #2

Closed
bdarcus opened this issue May 25, 2023 · 0 comments
Closed

Limitations #2

bdarcus opened this issue May 25, 2023 · 0 comments

Comments

@bdarcus
Copy link
Owner

bdarcus commented May 25, 2023

The conversion isn't perfect.; either to JSON schema, or directly from the typescript.

From what I can tell, it means it's looser in places than intended.

See, for example:

bdarcus/csl-next#146

I've included this static file of what it should be, since it's easier to manually write it.

https://github.com/bdarcus/csln-rs/blob/main/src/bibliography/mod.rs

Also tried to isolate those patterns to smaller files that I can manually maintain, but still have these ATM:

csln.rs
1202:    AnythingArray(Vec<Option<serde_json::Value>>),

src/style/options.rs
1171:    AnythingArray(Vec<Option<serde_json::Value>>),

src/bibliography/reference.rs
1204:    AnythingArray(Vec<Option<serde_json::Value>>),

Also, need to fix contributor modeling there.

I also find the here script inconsistent on my different machines, so don't know what's going on.

If there's interest, could just host the converted code in the repo, and so it can be installed via cargo --git, for developers that may want to experiment with the models.

Could then also manually fix the conversion problems I note above, or ideally write a script so it could be automated.

But I'll likely need a PR for the cargo details; am a total Rust newbie.

I'm also experimenting with the opposite approach: a Rust-based model, converted to JSON Schema.

https://github.com/bdarcus/csln

Certainly fast and clean, but I need to see how good the actual schema files are.

@bdarcus bdarcus closed this as completed Jun 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant