#终端 #Unix之美 #构建 #SDK #行星 #插件 #头文件

planetary_core

用于构建行星插件的SDK

1 个不稳定版本

0.1.0 2023年5月2日

#224 in #头文件

MIT 许可协议

22KB
387

CratesIO Badge CratesIO Downloads CratesIO License

行星SDK

一个低代码SDK,用于构建出色的行星插件。

入门指南

planetary_core 添加到 Cargo.toml

[dependencies]
planetary_core = "0.1.0"

然后在您的应用中使用SDK

use planetary_core::prelude::*;

pub struct Plugin

impl Powerup<Root> for Plugin {
    fn prepare(&self) -> Result<PlanetaryRequest> {
        Ok(request!("POST", "url", /* headers */, /* Optional Body */))
    }

    fn execute(&self, data: Root) -> PrintableGrid {
        let mut printable = PrintableGrid::new();
        printable
    }
}


fn main() {
    Planetary::run("github", Plugin::new());
}

这是一个相对简单的示例。请在此处阅读 文档 以详细了解如何构建和发布出色的插件!

依赖关系

~4–15MB
~179K SLoC