Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add __abi-generate features to docs generated #1285

Open
3 of 4 tasks
dj8yfo opened this issue Dec 23, 2024 · 0 comments
Open
3 of 4 tasks

doc: add __abi-generate features to docs generated #1285

dj8yfo opened this issue Dec 23, 2024 · 0 comments
Labels

Comments

@dj8yfo
Copy link
Collaborator

dj8yfo commented Dec 23, 2024

It's not convenient that JsonSchema/BorshSchema cannot be checked on docs
https://docs.rs/near-sdk/5.7.0/near_sdk/struct.PublicKey.html of various types,
for being implemented or not.

diff --git a/near-contract-standards/Cargo.toml b/near-contract-standards/Cargo.toml
index e4ab1dfe..ccc8dcba 100644
--- a/near-contract-standards/Cargo.toml
+++ b/near-contract-standards/Cargo.toml
@@ -24,4 +24,7 @@ near-sdk = { path = "../near-sdk", default-features = false, features = [

+[package.metadata.docs.rs]
+features = ["abi"]
+
 [features]
 default = []
-abi = ["near-sdk/abi"]
+abi = ["near-sdk/__abi-generate"]
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 06bda06c..ca9fb168 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -125,5 +125,5 @@ jobs:
       run: |
-        cargo doc -p near-sdk --features unstable,legacy,unit-testing,__macro-docs
-        cargo doc -p near-sdk-macros
-        cargo doc -p near-contract-standards --no-deps
+        cargo doc -p near-sdk --features unstable,legacy,unit-testing,__macro-docs,__abi-generate
+        cargo doc -p near-sdk-macros --features __abi-generate
+        cargo doc -p near-contract-standards --no-deps --features abi
         cargo doc -p near-sys
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: NEW❗
Development

No branches or pull requests

1 participant