1.0.0-beta.4 • Published 8 months ago

bytefun-js v1.0.0-beta.4

Weekly downloads
-
License
LGPL-3.0-only
Repository
-
Last release
8 months ago

bytefun-js

ByteFun快速开发平台,web端的SDK

登录 ByteFun官网 查看更多信息

安装

使用 npm:

npm install bytefun-js

使用 yarn:

yarn add bytefun-js

使用

APP_ID 和 APP_KEY 请登录 ByteFun官网 获取。

AppConfig.js

export default  class AppConfig {
  public static readonly APP_ID = '你的appId'
  public static readonly APP_KEY = '你的appKey'
}

在项目中引入 SDK 并初始化,示例如下:

import { ByteFunSDK,Platform } from 'bytefun-js';

ByteFunSDK.init({
  el: '#app', // 挂载的根节点
  serverLib: new ByteFunServer(),
  appId: AppConfig.APP_ID,
  appKey: AppConfig.APP_KEY,
  platform: Platform.H5,
  debug: true, // 是否开启测试调试模式, 默认为false,正式发布之后需要去掉
})

ByteFunServer 接口实现:

import { IServerLib } from 'bytefun-js';
export class ByteFunServer implements IServerLib {
    ...
}

ByteFunServer 接口实现具体逻辑,具体请参考 ByteFun 官网文档 对应的DEMO工程

更多信息请访问 ByteFun 官网

1.0.0-beta.4

8 months ago

1.0.0-beta.3.5

8 months ago

1.0.0-beta.3.3

8 months ago

1.0.0-beta.3.4

8 months ago

1.0.0-beta.3.1

8 months ago

1.0.0-beta.3.2

8 months ago

1.0.0-beta.2

8 months ago

1.0.0-beta.3

8 months ago

1.0.1

1 year ago

1.0.0-beta.1

1 year ago

1.0.0

1 year ago