@datadayrepos/sdk_client_auth
v0.1.1-SNAPSHOT.202411141349
Published
OpenAPI client for @datadayrepos/sdk_client_auth
Downloads
457
Readme
Do not edit code in this repo
All code here is autogenerated from aby.dev/go-kit.
Build and Publish to NPM
The typescript is designed to be published as an open package to NPM.
We do this from the github TS repo, and not from the golang repo were the package is created. In Golang repo we publish the package to its own git.
We will eventually automate the build and publish step.
npm run build
npm publish --access public
Download from git
If syncing the package for the first time form github, open a new window in VSCODE, choose sync from Github. Find the apckage and sync.
Sync with local
Since the repo shall not be edited, but we use vscode locally to run the build and publish sequence, we might need to overwrite any local git version.
First, fetch the latest changes from the remote repository without merging them into your local branch. This updates your local copy of the remote branches.
git fetch origin
Replace all local code with the remote version, we can use the git reset --hard command to reset our local main branch to exactly match the origin/main branch.
git reset --hard origin/main
This command will:
Move the main branch pointer back to where origin/main is, discarding any divergent commits on your local main branch. Reset the staging area and working directory to match the state of origin/main, effectively discarding any local changes or commits that were not pushed to the remote repository.
After running the reset command, you can verify that your local branch is now in sync with the remote branch:
git status
Dataloss
There is a risk of data loss with these methods.
The git reset --hard command will discard local changes and commits that are not present on the remote branch. Ensure that there is no local work you wish to keep before running this command.
Backup: If you're unsure about discarding local changes, you can always create a backup branch before resettin
git branch backup-branch-name
This creates a new branch pointing to your current commit, allowing you to return to this state if necessary.## @datadayrepos/[email protected]
This generator creates TypeScript/JavaScript client that utilizes Fetch API. The generated Node module can be used in the following environments:
Environment
- Node.js
- Webpack
- Browserify
Language level
- ES5 - you must have a Promises/A+ library installed
- ES6
Module system
- CommonJS
- ES6 module system
It can be used in both TypeScript and JavaScript. In TypeScript, the definition will be automatically resolved via package.json
. (Reference)
Building
To build and compile the typescript sources to javascript use:
npm install
npm run build
Publishing
First build the package then run npm publish
Consuming
navigate to the folder of your consuming project and run one of the following commands.
published:
npm install @datadayrepos/[email protected] --save
unPublished (not recommended):
npm install PATH_TO_GENERATED_PACKAGE --save