Follow these steps to install the QuikDB SDK using your preferred package manager.

Next you may use your preferred package manager as shown below:

Note: Installing globally allows you to access the quikdb command from any directory.


Additional Notes

  • Permissions: If you encounter permission issues while installing globally, you might need to use sudo (for Unix-based systems) or run your terminal as an administrator (for Windows). For example:

    sudo npm install -g quikdb-cli-beta
    
  • Environment Variables: Ensure that your system’s PATH includes the directory where global npm or yarn packages are installed. This is typically handled automatically, but if you encounter issues accessing the quikdb command, you may need to adjust your PATH manually.

  • Updating the SDK: To update the QuikDB SDK to the latest version, you can run:

    npm update -g quikdb-cli-beta
    

    or

    yarn global upgrade quikdb-cli-beta
    

Initialize QuikDB Instance in your code.

With the SDK installed, you can now initialize an instance of QuikDB in your project. This instance will be used to interact with QuikDB canisters.

import { QuikDB } from 'quikdb-cli-beta/v1/sdk';

const quikdb = new QuikDB();

(async () => {
  await quikdb.init();
  console.log('QuikDB initialized successfully.');
})();

Step 5: Start Using Canister Methods

You’re now ready to perform various operations such as creating schemas, managing records, and querying data. Refer to the Canister Methods section for detailed information on available methods and their usage.


For more comprehensive examples and advanced usage, visit the Usage Examples section.