Components library for dApps Development with dHealth Network.
NOTE: The author(s) and contributor(s) of this package cannot be held responsible for any loss of money or for any malintentioned usage forms of this package. Please use this package with caution.
This library can be installed in your Javascript or Typescript project using npm install @dhealth/components
.
If you are developing a Vue software, note that you must register the components by installing the plugin on the Vue app instance.
// examples/GettingStartedWithVue.ts
// import
import { createApp } from 'vue'
import App from './App.vue'
import plugin from '@dhealth/components';
// install
createApp(App)
.use(plugin)
.mount("#app");
// examples/UseInVueTemplates.ts
// use in templates
import { DappTokenAmount } from '@dhealth/components';
new Vue({
el: '#app',
components: { DappTokenAmount },
template: '<DappTokenAmount />'
});
If you are developing a PWA / Browser application or mobile software, you may use the UMD bundle to leverage the features of this library.
Note: the following example uses Vue in-browser, this can be replaced by any other framework and libraries including React, React Native, Angular, amongst many others.
// examples/GettingStartedWithBrowser.ts
// install
Vue.use(window.dHealthComponents.default);
// use in templates
new Vue({
el: '#app',
template: '<DappTokenAmount />',
});
// or use programmatically
console.log(window.dHealthComponents.DappTokenAmount);
Use the following available resources to get help:
Contributions are welcome and appreciated. Check CONTRIBUTING for information on how to contribute.
Copyright 2022-present dHealth Network, All rights reserved.
Licensed under the LGPL v3.0
Generated using TypeDoc