Basic usage
Component have to be imported to your project and then you can use it in your template. Here is an example of usage
Standalone Component
Component can be used as Angular standalone component. It will be rendered in the place where you put it in your template. You can also pass props to it and listen to events.
Code example
import { Component, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
// import component from library
import '@fazio/ipfs-upload-button';
@Component({
standalone: true,
selector: 'app-root',
// add the following line to enable custom elements support
schemas: [CUSTOM_ELEMENTS_SCHEMA],
// use the component in your template
template: `
<div>
<web3-upload-btn token="{{token}}"></web3-upload-btn>
</div>
`
})
export class AppComponent {
token = 'WEB3STORAGE_APIKEY'
}