Skip to content

Commit

Permalink
Gen types for both cjs and esm
Browse files Browse the repository at this point in the history
  • Loading branch information
smaye81 committed Jul 28, 2023
1 parent 466f7c5 commit f732bd7
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions packages/protobuf/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,21 @@
"sideEffects": false,
"scripts": {
"clean": "rm -rf ./dist/cjs/* ./dist/esm/* ./dist/types/*",
"build": "npm run build:cjs && npm run build:esm+types",
"build:cjs": "../../node_modules/typescript/bin/tsc --project tsconfig.json --module commonjs --outDir ./dist/cjs && echo >./dist/cjs/package.json '{\"type\":\"commonjs\"}'",
"build:esm+types": "../../node_modules/typescript/bin/tsc --project tsconfig.json --module ES2015 --verbatimModuleSyntax --outDir ./dist/esm --declaration --declarationDir ./dist/types && cp ./dist/types/index.d.ts ./dist/types/index.d.cts",
"build": "npm run build:cjs && npm run build:esm",
"build:cjs": "../../node_modules/typescript/bin/tsc --project tsconfig.json --module commonjs --outDir ./dist/cjs --declaration --declarationDir ./dist/cjs && echo >./dist/cjs/package.json '{\"type\":\"commonjs\"}'",
"build:esm": "../../node_modules/typescript/bin/tsc --project tsconfig.json --module ES2015 --verbatimModuleSyntax --outDir ./dist/esm --declaration --declarationDir ./dist/esm",
"lint:types": "attw --pack"
},
"main": "./dist/cjs/index.js",
"type": "module",
"types": "./dist/types/index.d.ts",
"types": "./dist/esm/index.d.ts",
"exports": {
"import": {
"types": "./dist/types/index.d.ts",
"types": "./dist/esm/index.d.ts",
"default": "./dist/esm/index.js"
},
"require": {
"types": "./dist/types/index.d.cts",
"types": "./dist/cjs/index.d.ts",
"default": "./dist/cjs/index.js"
}
},
Expand Down

0 comments on commit f732bd7

Please sign in to comment.