【发布时间】:2018-02-23 19:51:22
【问题描述】:
如果接口内的变量键入为Uint8Array,可能的值是多少?
typeorm/src/driver/sqljs/SqljsConnectionOptions.ts https://github.com/typeorm/typeorm/blob/master/src/driver/sqljs/SqljsConnectionOptions.ts
/**
* Sql.js-specific connection options.
*/
export interface SqljsConnectionOptions extends BaseConnectionOptions {
/**
* A Uint8Array that gets imported when the connection is opened.
*/
readonly database?: Uint8Array;
}
如果已经阅读了MDN's article on Uint8Array,但它没有帮助。
编辑: 如您所见,需要一个数据库名称。直觉上我会以我的数据库的名称过去,但这是一个字符串。那么Uint8Array格式的数据库长什么样子呢?
【问题讨论】:
-
什么意思,它没有帮助?显然,声明为
Uint8Array的变量可以具有Uint8Array的值。例如。new Uint8Array(10)是它可以具有的值。您遇到的具体问题是什么?
标签: javascript typescript typeorm uint8array