1.3.1 • Published 2 years ago
@nnsdao/actorservice v1.3.1
NnsDao Service
Install
Install from Github
# Use default ssh account
npm i git@github.com:NnsDao/ActorService.git
# Or use another ssh account
npm i git+ssh://xxxx:NnsDao/ActorService.git
Install from npm
Config registry
# .npmrc
@nnsdao:registry=https://registry.npmjs.org/
npm install @nnsdao/actorservice
Install from Github packages
Config registry
# .npmrc
@nnsdao:registry=https://npm.pkg.github.com
npm install @nnsdao/actorservice
Usage
// import IDL
// import { idlFactory as proxyIDL } from 'actorservice/xxxx/index';
import { idlFactory as proxyIDL } from '@nnsdao/actorservice/market/index';
// import Service
// import {xxx as xxx } from 'actorservice/xxx/xxx.did'
import { _SERVICE as proxyActor } from '@nnsdao/actorservice/market/market.did';
Typescript warning
If you got this warning
Config Path alias at tsconfig.json
{
"compilerOptions": {
// xxx
"paths": {
// xxx
"@nnsdao/actorservice/*": ["./node_modules/@nnsdao/actorservice/src/*"]
}
}
}