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

fix: remove trpc + make client focus #45

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .env.development
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
NEXT_PUBLIC_BASE_URL='https://demo-api.dwarvesf.com/api/v1'
NEXT_PUBLIC_API_MOCKING=disabled
NEXT_PUBLIC_BASE_URL='/api'
3 changes: 0 additions & 3 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ on:
- opened
- synchronize

env:
NEXT_PUBLIC_BASE_URL: https://demo-api.dwarvesf.com/api/v1

jobs:
test:
runs-on: ubuntu-latest
Expand Down
102 changes: 0 additions & 102 deletions .spectral.js

This file was deleted.

4 changes: 2 additions & 2 deletions cypress/e2e/auth.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ describe('User Sign-up and Login', () => {

it('should allow a visitor to sign-up, login, and logout', function () {
const userInfo = {
email: 'demo@dwarves.foundation',
password: 'Testing@123',
email: 'test@d.foundation',
password: 'Thepassword1',
}

cy.visit('/')
Expand Down
22 changes: 8 additions & 14 deletions docs/GETTING_STARTED.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,6 @@ to see your project.
│── cypress # Cypress configuration and tests
├── tailwind.config.js # Tailwind CSS configuration
├── tsconfig.json # TypeScript configuration
├── .spectral.js # IBM OpenAPI Ruleset for Orval used on validating the rules for Swagger
└── orval.config.js # Orval api generator configuration
```

### Develop UI components
Expand All @@ -63,26 +61,22 @@ The UI document then should be live at

If your team use Swagger to document APIs, we support a node script to generate
TypeScript interfaces via your Swagger scheme. In
[orval.config.js](../orval.config.js), change the default path to the location
of your Swagger JSON doc.

```diff
input: {
- target: 'https://demo-api.dwarvesf.com/swagger/doc.json',
+ target: 'your-api-swagger-json',
...
}
[package.json](../package.json), change the default path to the location of your
Swagger JSON doc.

```
- "fetch-definitions": "swagger-typescript-api --no-client -p ./libs/swagger.json -o ./types -n schema.ts",
+ "fetch-definitions": "swagger-typescript-api --no-client -p your-api-swagger-json -o ./types -n schema.ts",

Then, you can run the script locally to generate TypeScript definitions for the
APIs:

```bash
pnpm generate:api
pnpm fetch-definitions
```

The generated models and api clients will be located at [api](../src/api)
folder.
The generated interfaces will be located at
[types/schema.ts](../types/schema.ts).

## Read on:

Expand Down
86 changes: 0 additions & 86 deletions orval.config.js

This file was deleted.

5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
"@tailwindcss/forms": "^0.5.7",
"classnames": "^2.5.1",
"isomorphic-unfetch": "^4.0.2",
"mitt": "^3.0.1",
"next": "14.2.5",
"nprogress": "^0.2.0",
"react": "18.3.1",
Expand Down Expand Up @@ -106,6 +105,7 @@
"stylelint": "^15.10.2",
"stylelint-config-prettier": "^9.0.4",
"stylelint-config-standard": "^34.0.0",
"swagger-typescript-api": "^13.0.16",
"tailwindcss": "3.4.9",
"tailwindcss-animate": "^1.0.7",
"ts-jest": "^29.2.4",
Expand All @@ -125,8 +125,5 @@
},
"engines": {
"pnpm": ">=8.2.0"
},
"msw": {
"workerDirectory": "public"
}
}
Loading
Loading