saleor-client-typescript
v4.0.0
Published
api client for saleor
Downloads
6
Readme
saleor-client-typescript
api client for saleor
built with https://github.com/bitjson/typescript-starter
and https://graphql-code-generator.com/
example usage
import { GraphQLClient } from 'graphql-request';
import { CategoryInput, getSdk } from 'saleor-client-typescript';
async function main() {
const myInput: CategoryInput = { name: 'foo', description: 'bar' };
const client = new GraphQLClient('http://localhost:8000/graphql/');
const sdk = getSdk(client);
const response = await sdk.categoryCreate({ input: myInput });
console.log(response);
}
Contributer guidelines
create feature branches to merge to master
commit with commitizen
npm install -g commitizen
# commit your changes:
git cz
before you merge to master, run
# bump package.json version, update CHANGELOG.md, git tag the release
yarn run version