feature request: support extensible data fields
tabcat opened this issue · 5 comments
I would like to add support for extensible data to this implementation of the IPNS record.
This could be done by:
- adding an optional
extensibleData
field toCreateOptions
. - adding an optional parameter
extensibleData
tocreateCborData
. - inside of createCborData, merge extensibleData the
data
object. - add tests and documentation
It's not necessary to change types or add generics to the record type. Users of this feature would simply have to decode IPNSRecord.data
to read any extensible fields.
Thank you for submitting your first issue to this repository! A maintainer will be here shortly to triage and review.
In the meantime, please double-check that you have provided all the necessary information to make this process easy! Any information that can help save additional round trips is useful! We currently aim to give initial feedback within two business days. If this does not happen, feel free to leave a comment.
Please keep an eye on how this issue will be labeled, as labels give an overview of priorities, assignments and additional actions requested by the maintainers:
- "Priority" labels will show how urgent this is for the team.
- "Status" labels will show if this is ready to be worked on, blocked, or in progress.
- "Need" labels will indicate if additional input or analysis is required.
Finally, remember to use https://discuss.ipfs.io if you just need general support.
Thank you for posting this issue, I had the exact same question, and you saved me the time reading through the docs
@tabcat if you want to use it check my tests, https://github.com/dentropy/js-ipns/blob/main/test/extensible_data.spec.ts
You have to recast js-ipns type IPNSRecordData as any to get the data out