@royalinvest/dto
v0.71.6
Published
Data Transfer Objects (DTOs) to carry data between frontend and backend processes.
Keywords
Readme
NPM Packages
This project contains shared NPM packages for RoyalInvest (e.g., DTOs, utilities).
Packages are written in TypeScript and published to the company’s NPM organization.
Getting Started
1. Configure NPM registry
To authenticate with the NPM registry, configure your .npmrc file:
npm config set //registry.npmjs.org/:_authToken=<your_auth_token>Replace <your_auth_token> with a token from npmjs.com.
For access to the company’s account, request a token from the administrator.
Company Packages
You can view all published packages here:
RoyalInvest NPM Packages
Creating a New Package
- Create a new directory under
npm-package/. - Add:
package.json(copy structure fromdto/package.json).tsconfig.json(same as in existing packages).
- Implement your code in
src/.
Each package should follow the same conventions for consistency.
Building a Package
Run the build command inside the package directory:
npm run buildCheck the scripts section in dto/package.json for an example configuration.
Versioning
We follow Semantic Versioning (SemVer):
- MAJOR – incompatible API changes
- MINOR – add functionality in a backward-compatible manner
- PATCH – backward-compatible bug fixes
Update the version number manually in package.json before publishing.
Publishing
To publish a package to the NPM registry:
npm publish --access public