Releases: clockworklabs/spacetimedb-typescript-sdk
@clockworklabs/[email protected]
Changelog
1.0.0-rc1.0
Major Changes
Minor Changes
-
#110
a501f5c
Thanks @Centril! - Support light tx updates via builder.with_light_mode(_) and the call flag NoSuccessNotify -
#119
6547882
Thanks @kazimuth! - Update Identity and Address to use bigints rather than byte arrays (see clockworklabs/SpacetimeDB#1616)
Patch Changes
0.12.1
Patch Changes
-
#107
2f6c82c
Thanks @PuruVJ! - fix: websocket message handling, Buffer, onConnect -
#108
b9db9b6
Thanks @PuruVJ! - docs: Public facing docs for 0.12 -
#105
79c278b
Thanks @PuruVJ! - fix: temporary token path invocation
0.12.0
Minor Changes
-
#92
ab1f463
Thanks @PuruVJ! - breaking: Flatten AlgebraicType & Simplify some codegen -
#102
b8c944c
Thanks @cloutiertyler! - internal: Remove global instance, allow multiple connections
Patch Changes
-
#91
5adb557
Thanks @PuruVJ! - types: Allow autocomplete in .on and .off types -
#96
17227c0
Thanks @PuruVJ! - (fix) Synchronous WS Processing
0.8.0 (2023-12-11)
Bug Fixes
- Properly use BigInt for any numbers bigger than 32 bits
- Fix generating primary key names to be camel case
Features
-
Added ability to start multiple SpacetimeDB clients. New clients will have a separate ClientDB
-
Changed the return type of functions returning table records - now they are arras instead of iterators
-
Reducer callbacks have args passed in separately, which makes it easier to know what types they are
For example a reducer taking a single string argument will have a callback signature like(reducerEvent: ReducerEvent, name: string)
instead of(reducerEvent: ReducerEvent, args: any[])
-
We now require explicitly registering any tables or reducers with
SpacetimeDBClient.registerReducers()
andSpacetimeDBClient.registerTables()
.
This also allows to register child classes, which in turn allows to use customized table classes. We will add more info
on how to do it in the future. This makes it also harder to run into weird issues. If you only import a reducer, but not use
it to set any callbacks, Node.js will filter out the import. If you then subscribe to a table SpacetimeDBClient will be unable
to find the reducer. To ensure this is not happening people were adding aconsole.log
statement listing and used classes to
stop Node.js from filtering out any imports, likeconsole.log(SayHelloReducer)
. Now with the reducer call it's more explicit -
In this release we have also moved some methods from generated types into the SDK, which should result in a smaller footprint from
generated classes -
Generated sum types are now easier to use. For sum types without any values you can use their type name as value, for example given an
enum in Rust:enum UserRole { Admin, Moderator, User, Other(String) }
you can now use types itself as values. For example given a reducer for setting a role you could now do the following in TypeScript:
SetRoleReducer.call(UserRole.Admin); SetRoleReducer.call(UserRole.Other('another role'));
@clockworklabs/[email protected]
Changelog
1.0.0-rc1.0
Major Changes
Minor Changes
-
#110
a501f5c
Thanks @Centril! - Support light tx updates via builder.with_light_mode(_) and the call flag NoSuccessNotify -
#119
6547882
Thanks @kazimuth! - Update Identity and Address to use bigints rather than byte arrays (see clockworklabs/SpacetimeDB#1616)
Patch Changes
0.12.1
Patch Changes
-
#107
2f6c82c
Thanks @PuruVJ! - fix: websocket message handling, Buffer, onConnect -
#108
b9db9b6
Thanks @PuruVJ! - docs: Public facing docs for 0.12 -
#105
79c278b
Thanks @PuruVJ! - fix: temporary token path invocation
0.12.0
Minor Changes
-
#92
ab1f463
Thanks @PuruVJ! - breaking: Flatten AlgebraicType & Simplify some codegen -
#102
b8c944c
Thanks @cloutiertyler! - internal: Remove global instance, allow multiple connections
Patch Changes
-
#91
5adb557
Thanks @PuruVJ! - types: Allow autocomplete in .on and .off types -
#96
17227c0
Thanks @PuruVJ! - (fix) Synchronous WS Processing
0.8.0 (2023-12-11)
Bug Fixes
- Properly use BigInt for any numbers bigger than 32 bits
- Fix generating primary key names to be camel case
Features
-
Added ability to start multiple SpacetimeDB clients. New clients will have a separate ClientDB
-
Changed the return type of functions returning table records - now they are arras instead of iterators
-
Reducer callbacks have args passed in separately, which makes it easier to know what types they are
For example a reducer taking a single string argument will have a callback signature like(reducerEvent: ReducerEvent, name: string)
instead of(reducerEvent: ReducerEvent, args: any[])
-
We now require explicitly registering any tables or reducers with
SpacetimeDBClient.registerReducers()
andSpacetimeDBClient.registerTables()
.
This also allows to register child classes, which in turn allows to use customized table classes. We will add more info
on how to do it in the future. This makes it also harder to run into weird issues. If you only import a reducer, but not use
it to set any callbacks, Node.js will filter out the import. If you then subscribe to a table SpacetimeDBClient will be unable
to find the reducer. To ensure this is not happening people were adding aconsole.log
statement listing and used classes to
stop Node.js from filtering out any imports, likeconsole.log(SayHelloReducer)
. Now with the reducer call it's more explicit -
In this release we have also moved some methods from generated types into the SDK, which should result in a smaller footprint from
generated classes -
Generated sum types are now easier to use. For sum types without any values you can use their type name as value, for example given an
enum in Rust:enum UserRole { Admin, Moderator, User, Other(String) }
you can now use types itself as values. For example given a reducer for setting a role you could now do the following in TypeScript:
SetRoleReducer.call(UserRole.Admin); SetRoleReducer.call(UserRole.Other('another role'));
@clockworklabs/[email protected]
Changelog
1.0.0-rc1.0
Major Changes
Minor Changes
-
#110
a501f5c
Thanks @Centril! - Support light tx updates via builder.with_light_mode(_) and the call flag NoSuccessNotify -
#119
6547882
Thanks @kazimuth! - Update Identity and Address to use bigints rather than byte arrays (see clockworklabs/SpacetimeDB#1616)
Patch Changes
0.12.1
Patch Changes
-
#107
2f6c82c
Thanks @PuruVJ! - fix: websocket message handling, Buffer, onConnect -
#108
b9db9b6
Thanks @PuruVJ! - docs: Public facing docs for 0.12 -
#105
79c278b
Thanks @PuruVJ! - fix: temporary token path invocation
0.12.0
Minor Changes
-
#92
ab1f463
Thanks @PuruVJ! - breaking: Flatten AlgebraicType & Simplify some codegen -
#102
b8c944c
Thanks @cloutiertyler! - internal: Remove global instance, allow multiple connections
Patch Changes
-
#91
5adb557
Thanks @PuruVJ! - types: Allow autocomplete in .on and .off types -
#96
17227c0
Thanks @PuruVJ! - (fix) Synchronous WS Processing
0.8.0 (2023-12-11)
Bug Fixes
- Properly use BigInt for any numbers bigger than 32 bits
- Fix generating primary key names to be camel case
Features
-
Added ability to start multiple SpacetimeDB clients. New clients will have a separate ClientDB
-
Changed the return type of functions returning table records - now they are arras instead of iterators
-
Reducer callbacks have args passed in separately, which makes it easier to know what types they are
For example a reducer taking a single string argument will have a callback signature like(reducerEvent: ReducerEvent, name: string)
instead of(reducerEvent: ReducerEvent, args: any[])
-
We now require explicitly registering any tables or reducers with
SpacetimeDBClient.registerReducers()
andSpacetimeDBClient.registerTables()
.
This also allows to register child classes, which in turn allows to use customized table classes. We will add more info
on how to do it in the future. This makes it also harder to run into weird issues. If you only import a reducer, but not use
it to set any callbacks, Node.js will filter out the import. If you then subscribe to a table SpacetimeDBClient will be unable
to find the reducer. To ensure this is not happening people were adding aconsole.log
statement listing and used classes to
stop Node.js from filtering out any imports, likeconsole.log(SayHelloReducer)
. Now with the reducer call it's more explicit -
In this release we have also moved some methods from generated types into the SDK, which should result in a smaller footprint from
generated classes -
Generated sum types are now easier to use. For sum types without any values you can use their type name as value, for example given an
enum in Rust:enum UserRole { Admin, Moderator, User, Other(String) }
you can now use types itself as values. For example given a reducer for setting a role you could now do the following in TypeScript:
SetRoleReducer.call(UserRole.Admin); SetRoleReducer.call(UserRole.Other('another role'));
@clockworklabs/[email protected]
Major Changes
Minor Changes
-
#110
a501f5c
Thanks @Centril! - Support light tx updates via builder.with_light_mode(_) and the call flag NoSuccessNotify -
#119
6547882
Thanks @kazimuth! - Update Identity and Address to use bigints rather than byte arrays (see clockworklabs/SpacetimeDB#1616)