
Stellar Nest provides an easy way to kickstart a project in Stellar with NestJS. One module to rule them all.
Taking advantage of NestJS's versatility, stellar-nest provides a pre-configurable module. This means that both users unrelated to the Stellar ecosystem and those aiming to accelerate their Node.js development will find a pleasant surprise when using stellar-nest.
Drawing on the best practices recommended in the Stellar documentation, this module will enable a quick start. However, it will remain fully customizable depending on the development needs and will adapt accordingly. For instance, initializing the module in 'TESTNET' mode would generate an instance of the serverService pointing to the testnet server, utilizing the appropriate Network Passphrase depending on the mode. Nevertheless, this doesn't compromise power; at any point, you can modify the server configuration directly from the module, and this configuration would be applied to the serverService (which is actually the extended Horizon.server class).
For example, upon creating accounts, you could establish an initial trustline or choose an initial balance, all according to business rules. All of this will be completely customizable from the module configuration.
One module to bring them all.
Although it could be useful for various use cases, one of the main objectives is to accelerate certain processes and introduce Stellar to non-blockchain developers. With this recommended default configuration, it would be easy for them to integrate Stellar into their projects even if they are not directly related to blockchain.
In the land of development, where magic meets code, stellar-nest proposes working based on use cases, making it more intuitive to choose the utility to use depending on the circumstance. Leveraging the magic of TypeScript and Nest, a series of decorators, pipes, and additional functionalities are being prepared.
An easy example would be the balance decorator @BalanceParam(). For instance, a startup's service may want to retrieve the balance of an account based on a parameter, body, or formData when a controller is used, without needing to adapt the logic to fetch balances. @BalanceParam allows specifying the parameter name, along with additional configuration such as specifying the asset_code to know the exact balance of that account, thus enabling early return if a certain condition is not met, even before executing other logics.
$14.8K

No other submissions.