Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sepolia deploy #23

Merged
merged 10 commits into from
Jan 3, 2024
5 changes: 5 additions & 0 deletions .changeset/flat-wasps-matter.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@valorem-labs-inc/sdk': patch
---

add arbitrum sepolia deployments; drop arbitrum goerli
5 changes: 5 additions & 0 deletions .changeset/violet-points-exist.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@valorem-labs-inc/sdk": patch
---

drop parcel for tsup...
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ jobs:

- name: Install packages, compile SDK, and build docs
run: |
pnpm ci:preinstall
pnpm i
pnpm generate
pnpm gen-docs
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ jobs:

- name: Install packages, build, lint, and test
run: |
pnpm ci:preinstall
pnpm i
pnpm audit
pnpm build
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ dist

coverage

src/lib/codegen
src/lib/grpc/codegen
src/lib/subgraph/codegen
src/lib/trade-interfaces

docs
Expand Down
8 changes: 0 additions & 8 deletions .parcelrc

This file was deleted.

8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,21 +45,21 @@ the ValoremSDK. Here's a quick start guide:
```typescript
import { createPublicClient, createWalletClient, http } from 'viem';
import { privateKeyToAccount } from 'viem/accounts';
import { arbitrumGoerli } from 'viem/chains';
import { arbitrumSepolia } from 'viem/chains';
import { ValoremSDK } from '@valorem-labs-inc/sdk';

// Replace YOUR_PRIVATE_KEY with your Ethereum private key.
const account = privateKeyToAccount(YOUR_PRIVATE_KEY);

// Set up Viem clients for the Arbitrum Goerli test network.
// Set up Viem clients for the Arbitrum Sepolia test network.
const publicClient = createPublicClient({
chain: arbitrumGoerli,
chain: arbitrumSepolia,
transport: http(),
});

const walletClient = createWalletClient({
account,
chain: arbitrumGoerli,
chain: arbitrumSepolia,
transport: http(),
});

Expand Down
4 changes: 2 additions & 2 deletions buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: v1
plugins:
- plugin: es
opt: target=ts+js+dts
out: src/lib/codegen/grpc
out: src/lib/grpc/codegen
- plugin: connect-es
opt: target=ts+js+dts
out: src/lib/codegen/grpc
out: src/lib/grpc/codegen
2 changes: 1 addition & 1 deletion codegen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const config: CodegenConfig = {
documents: ['src/**/!(*.d).{ts,tsx}'],
ignoreNoDocuments: true,
generates: {
'./src/lib/codegen/gql/': {
'./src/lib/subgraph/codegen/': {
preset: 'client',
config: {
strictScalars: true,
Expand Down
77 changes: 66 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,76 @@
"license": "MIT",
"sideEffects": false,
"type": "module",
"main": "dist/main.js",
"exports": {
".": {
"types": "./dist/index.d.ts",
"default": "./dist/index.mjs"
},
"./constants": {
"types": "./dist/constants.d.ts",
"default": "./dist/constants.mjs"
},
"./abi": {
"types": "./dist/abi/index.d.ts",
"default": "./dist/abi/index.mjs"
},
"./entities": {
"types": "./dist/entities/index.d.ts",
"default": "./dist/entities/index.mjs"
},
"./entities/assets": {
"types": "./dist/entities/assets/index.d.ts",
"default": "./dist/entities/assets/index.mjs"
},
"./entities/contracts": {
"types": "./dist/entities/contracts/index.d.ts",
"default": "./dist/entities/contracts/index.mjs"
},
"./entities/options": {
"types": "./dist/entities/options/index.d.ts",
"default": "./dist/entities/options/index.mjs"
},
"./entities/trader": {
"types": "./dist/entities/trader/index.d.ts",
"default": "./dist/entities/trader/index.mjs"
},
"./lib": {
"types": "./dist/lib/index.d.ts",
"default": "./dist/lib/index.mjs"
},
"./lib/grpc": {
"types": "./dist/lib/grpc/index.d.ts",
"default": "./dist/lib/grpc/index.mjs"
},
"./lib/subgraph": {
"types": "./dist/subgraph/index.d.ts",
"default": "./dist/subgraph/index.mjs"
},
"./utils": {
"types": "./dist/utils/index.d.ts",
"default": "./dist/utils/index.mjs"
},
"./package.json": "./package.json"
},
"main": "dist/index.mjs",
"source": "src/index.ts",
"types": "dist/types.d.ts",
"types": "dist/index.d.ts",
"files": [
"/abi",
"/entities",
"/lib",
"/utils",
"/dist"
],
"scripts": {
"build": "pnpm clean && pnpm generate && pnpm parcel build --no-cache",
"build": "pnpm clean && pnpm generate && pnpm tsup",
"ci:preinstall": "pnpm i -g node-gyp-build node-gyp-build-optional-packages",
"ci:release": "pnpm build && pnpm changeset publish",
"clean": "rm -rf ./dist",
"format": "prettier --write \"**/*.{ts,tsx,md,json}\"",
"gen-docs": "typedoc",
"generate": "pnpm generate:clean && pnpm generate:grpc && pnpm generate:gql",
"generate:clean": "rm -rf ./src/lib/codegen",
"generate:clean": "rm -rf ./src/lib/subgraph/codegen && rm -rf ./src/lib/grpc/codegen",
"generate:gql": "graphql-codegen",
"generate:grpc": "npx buf generate",
"lint": "eslint .",
Expand All @@ -29,7 +88,7 @@
"prettier": "@vercel/style-guide/prettier",
"dependencies": {
"@graphql-typed-document-node/core": "^3.2.0",
"date-fns": "^3.0.5",
"date-fns": "^3.0.6",
"graphql": "^16.8.1",
"mathjs": "^12.2.1"
},
Expand All @@ -44,17 +103,13 @@
"@graphql-codegen/client-preset": "^4.1.0",
"@graphql-codegen/typescript": "^4.0.1",
"@graphql-codegen/typescript-operations": "^4.0.1",
"@parcel/config-default": "^2.10.3",
"@parcel/packager-ts": "^2.10.3",
"@parcel/transformer-typescript-tsc": "^2.10.3",
"@parcel/transformer-typescript-types": "^2.10.3",
"@types/node": "^20.10.5",
"@vercel/style-guide": "^5.1.0",
"@vitest/coverage-v8": "^1.1.0",
"eslint": "^8.56.0",
"eslint-config-canonical": "^42.8.0",
"parcel": "^2.10.3",
"prettier": "^3.1.1",
"tsup": "^8.0.1",
"typedoc": "^0.25.4",
"typedoc-plugin-missing-exports": "^2.1.0",
"vitest": "^1.1.0"
Expand All @@ -64,7 +119,7 @@
"@connectrpc/connect": "^1.2.0",
"@wagmi/core": "^1.4.12",
"typescript": "^5.3.0",
"viem": "^1.19.15"
"viem": "^1.21.1"
},
"peerDependenciesMeta": {
"typescript": {
Expand Down
Loading