Gno: An interpreted, stack-based Go virtual machine to build succinct and composable apps + Gno.land: a blockchain for timeless code and fair open-source
While using gno-js and reading the related docs, I saw the message saying that it's based on tm2-js-client with related link.
This is useful to understand how it works and see the available methods from the base Provider classes, but doesn't inform the developer about how he should instantiate a provider with gno-js-client, the name of the providers isn't mentioned anywhere and I had to guess it (or use my IDE autocomplete) and look at other projects using it to find out.
This PR adds a small section to the documentation page with explicit instantiation examples to fix this (without repeating too much info, parameters for example are linked to tm2-js-client, but could be extended in the future and documented here).
Contributors' checklist...
- [ ] Added new tests, or not needed, or not feasible
- [ ] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory
- [x] Updated the official documentation or not needed
- [ ] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description
- [ ] Added references to related issues and PRs
- [ ] Provided any useful hints for running manual tests
- [ ] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md).
While using
gno-js
and reading the related docs, I saw the message saying that it's based ontm2-js-client
with related link. This is useful to understand how it works and see the available methods from the base Provider classes, but doesn't inform the developer about how he should instantiate a provider withgno-js-client
, the name of the providers isn't mentioned anywhere and I had to guess it (or use my IDE autocomplete) and look at other projects using it to find out.This PR adds a small section to the documentation page with explicit instantiation examples to fix this (without repeating too much info, parameters for example are linked to
tm2-js-client
, but could be extended in the future and documented here).Contributors' checklist...
- [ ] Added new tests, or not needed, or not feasible - [ ] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory - [x] Updated the official documentation or not needed - [ ] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description - [ ] Added references to related issues and PRs - [ ] Provided any useful hints for running manual tests - [ ] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md).