v0.0.4
rethink_db_ns
이것은 Dart와 Flutter에서 RethinkDB를 사용하기 위한 공식이 아닌 드라이버로, 널 안전성을 지원합니다. 이 드라이버는 포크 기반입니다 https://github.com/marceloneppel/rethinkdb
25좋아요 1830일 다운로드110Pub 점수
AndroidiOSmacOSWindowsLinux
Rethinkdb Flutter 패키지
아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.
This is a fork of Dart 2 and Flutter RethinkDB Driver with null safety 💪🏼 support and less dependencies.
Install from Pub
dart pub add rethink_db_ns
# or
flutter pub add rethink_db_ns
dependencies:
rethink_db_ns: ^0.0.4
Install from Github
dependencies:
rethink_db:
git:
url: git://github.com/G0mb/rethink_db.git
ref: main
Then import the package into your project:
import 'package:rethink_db_ns/rethink_db_ns.dart';
RethinkDb r = RethinkDb();
final connection = await r.connection(
db: 'test',
host: 'localhost',
port: 28015,
user: 'admin',
password: '',
);
// Create table
await r.db('test').tableCreate('tv_shows').run(connection);
// Insert data
await r.table('tv_shows').insert([
{'name': 'Star Trek TNG', 'episodes': 178},
{'name': 'Battlestar Galactica', 'episodes': 75}
]).run(connection);
// Fetch data
var result = await r.table('tv_shows').get(1).run(connection);
I recommend reviewing the RethinkDB Documentation for other types of queries.
More examples will be added soon...
dart test