Skip to content

Commit

Permalink
fix(dips): publish js files in the dips-proto npm package (#638)
Browse files Browse the repository at this point in the history
* fix(dips): publish js files in the dips-proto npm package

* fix: include protobuf dependency

---------

Co-authored-by: Filipe Azevedo <[email protected]>
  • Loading branch information
pcarranzav and mangas authored Feb 19, 2025
1 parent 454c925 commit 39ae705
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 7 deletions.
26 changes: 23 additions & 3 deletions crates/dips/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 9 additions & 4 deletions crates/dips/package.json
Original file line number Diff line number Diff line change
@@ -1,21 +1,26 @@
{
"name": "@graphprotocol/dips-proto",
"version": "0.2.1",
"version": "0.2.2",
"main": "generated/index.js",
"types": "generated/index.d.ts",
"files": [
"proto/**/*.proto",
"generated/**/*"
],
"scripts": {
"prepublishOnly": "npm run generate",
"generate": "mkdir -p generated && protoc --plugin=protoc-gen-ts_proto=./node_modules/.bin/protoc-gen-ts_proto --ts_proto_out=./generated --proto_path=./proto proto/*.proto"
"build": "tsc",
"generate": "mkdir -p generated && protoc --plugin=protoc-gen-ts_proto=./node_modules/.bin/protoc-gen-ts_proto --ts_proto_out=./generated --proto_path=./proto proto/*.proto",
"prepublishOnly": "npm run generate && npm run build"
},
"devDependencies": {
"@types/node": "^22.13.4",
"ts-proto": "^2.6.1",
"typescript": "^5.7.3"
},
"publishConfig": {
"access": "public"
},
"dependencies": {
"@bufbuild/protobuf": "^2.2.3"
}
}
}
16 changes: 16 additions & 0 deletions crates/dips/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"compilerOptions": {
"target": "es2018",
"module": "commonjs",
"declaration": true,
"outDir": "./generated",
"strict": true,
"esModuleInterop": true,
"skipLibCheck": true,
"forceConsistentCasingInFileNames": true,
"lib": ["es2018", "dom"],
"types": ["node"]
},
"include": ["generated/**/*"],
"exclude": ["node_modules"]
}

0 comments on commit 39ae705

Please sign in to comment.