Skip to content

Commit

Permalink
refactor: Add CONTRIBUTING.md and update README.md
Browse files Browse the repository at this point in the history
This commit adds a CONTRIBUTING.md file to provide guidelines for contributing to the MTS SDK project. It also updates the README.md file with usage examples and information about the Assets service in the MyTonSwap client.

[Issue #123]
  • Loading branch information
Ho3einWave committed Oct 30, 2024
1 parent 7a4f1ce commit a61d256
Show file tree
Hide file tree
Showing 2 changed files with 83 additions and 6 deletions.
44 changes: 44 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Contributing to MTS SDK

Thank you for considering contributing to the MTS SDK project! We welcome contributions from the community and are grateful for your support.

## How to Contribute

### Reporting Bugs

If you find a bug, please report it by opening an issue on our [GitHub Issues](https://github.com/your-repo/mts-sdk/issues) page. Provide as much detail as possible, including steps to reproduce the issue and any relevant logs or screenshots.

### Feature Requests

We are always looking to improve the MTS SDK. If you have a feature request, please open an issue on our [GitHub Issues](https://github.com/your-repo/mts-sdk/issues) page and describe the feature in detail.

### Submitting Changes

1. **Fork the Repository**: Fork the project on GitHub and clone your fork locally.
2. **Create a Branch**: Create a new branch for your changes (`git checkout -b my-feature-branch`).
3. **Make Changes**: Make your changes to the codebase.
4. **Commit Changes**: Commit your changes with a clear and concise commit message (`git commit -m "Add new feature"`).
5. **Push Changes**: Push your changes to your fork (`git push origin my-feature-branch`).
6. **Open a Pull Request**: Open a pull request on the main repository and provide a detailed description of your changes.

### Code Style

Please ensure your code adheres to the project's coding standards. We use [Prettier](https://prettier.io/) for code formatting. Run `npm run format` before committing your changes.

### Testing

Ensure that your changes do not break existing tests and add new tests for any new functionality. Run the test suite using `npm test`.

### Documentation

Update the documentation to reflect any changes or new features. This includes updating the README.md and any other relevant documentation files.

## Code of Conduct

Please note that this project is released with a [Contributor Code of Conduct](CODE_OF_CONDUCT.md). By participating in this project, you agree to abide by its terms.

## Getting Help

If you need help or have any questions, feel free to reach out by opening an issue or contacting the maintainers.

Thank you for your contributions!
45 changes: 39 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,48 @@
<p align="center">SDK for MyTonSwap DEX aggregator</p>


### ⚠️ Active Development Notice ⚠️
This project is currently under active development and is not yet ready for public use.

We recommend you DO NOT use this project in production environments until a stable release is announced. Expect frequent changes, updates, and possible breaking changes during this phase.


Installation:

```bash
npm install @mytonswap/sdk
```

## Usage

Here's a basic example of how to use the MyTonSwap SDK:

```ts
import { MyTonSwapClient } from '@mytonswap/sdk';

const client = new MyTonSwapClient();

async function performSwap() {
const userWallet = 'your-wallet-address';
const TON = await client.assets.getExactAsset('TON');
const NOT = await client.assets.getExactAsset('NOT');
const bestRoute = await client.router.findBestRoute(
TON!.address,
NOT!.address,
toNano(1),
1,
);

const swap = await client.swap.createSwap(userWallet, bestRoute);
console.log(swap);
}

performSwap();
```


## Contributing

We welcome contributions! Please read our [contributing guidelines](CONTRIBUTING.md) before submitting a pull request.

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

## Support

If you have any questions or need help, feel free to open an issue on our [GitHub repository](https://github.com/MyTonSwap/sdk/issues).

0 comments on commit a61d256

Please sign in to comment.