Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
julianbenegas committed Jun 6, 2023
1 parent 6e5669b commit 6524e26
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import {
type ClientOptions,
GenqlError,
} from './runtime/index'
export type { FieldsSelection }
export { GenqlError }

import types from './types'
Expand Down
2 changes: 1 addition & 1 deletion packages/sdk-gen/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@bsmnt/sdk-gen",
"author": "basement.studio <[email protected]>",
"version": "2.0.3",
"version": "2.0.4",
"main": "./dist/index.js",
"types": "./dist/types.d.ts",
"bin": {
Expand Down
5 changes: 2 additions & 3 deletions packages/sdk-gen/src/generate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,11 @@ export async function main(args: Args) {
}

// some misc fixes
// replace line 18 with `} from './runtime/index'`
const schemaFileContents = fs.readFileSync(generatedMainExportPath, 'utf-8')
const lines = schemaFileContents.split('\n')
// patch some lines to fix a weird rollup error.
lines[17] = "} from './runtime/index'"
// remove line 19
lines.splice(18, 1)
lines[18] = 'export type { FieldsSelection }'
fs.writeFileSync(generatedMainExportPath, lines.join('\n'))

console.log('Generated ✨')
Expand Down

1 comment on commit 6524e26

@vercel
Copy link

@vercel vercel bot commented on 6524e26 Jun 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

commerce-toolkit-nextjs-shopify – ./examples/nextjs-shopify

commerce-toolkit-nextjs-shopify.vercel.app
commerce-toolkit-nextjs-shopify-git-main-basement.vercel.app
commerce-toolkit-nextjs-shopify-basement.vercel.app

Please sign in to comment.