Migration
Migration guides for new versions of the webnative SDK
Webnative
Some versions of Webnative require apps to migrate their codebase to address breaking changes. Versions with changes are listed below.
Version 0.35.0
This version of Webnative is a major rewrite. Most apps will only need to update their initialization, permission request, and registration code to use the new APIs.
In previous versions, Webnative was initialized using the initialise
or app
functions that returned a state
object:
In Webnative 0.35, Webnative is initialized by creating namespaced programs and creating sessions.
Initialize a program with permissions
when your app requests capability from the Fission Auth Lobby.
Apps with root authority initialize without permissions
and use authentication strategies to register users and create sessions:
In both cases, the program will have an authenticated session at initialization when a user returns for another visit.
See the Initialization, Session, Requesting Capabilities, and Authentication Strategies sections for more details on the new APIs.
Webnative 0.35 also updates the file system interface so that only Uint8Array
can be written to and read from WNFS. If you are storing strings or other types of data, you will need to convert them Uint8Array
before writes and convert them from Uint8Array
on reads.
For example, writing a string to a file and later reading it looks like this:
Please review the CHANGELOG for an overview of the other changes in this version.
Version 0.28.0
The publicReadKey
function in keystore-idb
was renamed topublicExchangeKey
.
Most users will not need to change anything for webnative 0.28.0, unless they are interacting directly with keystore-idb.
Version 0.27.0
The type of App
returned app.index
has changed. Previously, the return type was
In Webnative 0.27.0, the the return type is
The domain for the app is now in the domains
array.
Version 0.26.1
The URL for loading webnative from UNPKG has changed. In Webnative 0.26.0, Webnative was available as index.min.js
.
We found that some projects needed the UMD build and brought it back in Webnative 0.26.1. We have replaced index.min.js
with index.umd.min.js
.
Version 0.26.0
The URL for loading webnative from UNPKG has changed. In previous versions, Webnative was available as index.umd.js
.
In Webnative 0.26, Webnative is available as index.min.js
.
Version 0.24
The way paths are used throughout the Webnative and filesystem APIs has changed.
In earlier versions of Webnative, API calls expected UNIX style paths.
In Webnative 0.24, paths are created by path helper functions for files and directories.
The docs for the previous API remain available for reference.
Last updated