Skip to content

Commit dd0c400

Browse files
authored
Merge pull request #26 from Weaverse/chore/200-viteplus-checks
chore: replace Biome with Vite+ checks (Oxlint/Oxfmt)
2 parents 3f0887d + 2787c76 commit dd0c400

77 files changed

Lines changed: 9408 additions & 6587 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/workflows/ci.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ jobs:
2525
run: npm install --global npm@10.9.8 --no-audit --no-fund
2626
- name: Install from the committed lockfile
2727
run: npm ci --engine-strict --no-audit --no-fund
28-
- name: Check source with Biome
29-
run: npm run biome
28+
- name: Static checks
29+
run: npm run check
3030
- name: Generate GraphQL types
3131
run: npm run codegen
3232
- name: Check types

‎.github/workflows/sync-worker-deploy.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ jobs:
7272
run: npm ci
7373

7474
- name: Validate Cloudflare build
75-
run: npm run check
75+
run: npm run cf-check
7676

7777
- name: Verify main is included
7878
run: git merge-base --is-ancestor origin/main HEAD

‎CLAUDE.md‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
1515
- `npm run codegen` - Generate GraphQL types and schema
1616

1717
### Code Quality
18-
- `npm run biome` - Run Biome checks and report errors and warnings
19-
- `npm run biome:fix` - Auto-fix linting issues
20-
- `npm run format` - Format code with Biome
18+
- `npm run check` - Run Oxfmt and Oxlint through `vp check`
19+
- `npm run check:fix` - Format and apply safe lint fixes
20+
- `npm run format` - Format code with Oxfmt
2121
- `npm run format:check` - Check formatting without changes
2222

2323
### Testing
@@ -36,7 +36,7 @@ This is a **Shopify Hydrogen storefront** built with **React Router v7** (not Re
3636
- **React Router 7.16** - Programmatic route configuration (NOT Remix - see import rules below)
3737
- **Weaverse** - Visual page builder with component system
3838
- **Vite** - Build tool and dev server
39-
- **Biome** - Linting and formatting (replaces ESLint/Prettier)
39+
- **Vite+** - Oxlint and Oxfmt, without changing the Vite build
4040
- **TailwindCSS v4** - Styling with CSS-in-JS approach
4141

4242
### Key Directory Structure
@@ -131,7 +131,7 @@ export let schema = createSchema({
131131

132132
### Code Quality Standards
133133
- **TypeScript**: Strict mode disabled, but use types where beneficial
134-
- **Linting**: Biome configuration in `biome.json` (extends `@weaverse/biome`)
134+
- **Linting**: Oxlint rules in the `lint` block of `vite.config.ts`
135135
- **Formatting**: Double quotes, semicolons required
136136
- **Imports**: Use `~/*` alias for app directory imports
137137

‎README.md‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ _Aspen is a sophisticated Shopify theme crafted specifically for home furniture
2323
- Hydrogen 2026.4
2424
- Oxygen
2525
- Shopify CLI
26-
- Biome (ESLint, Prettier alternative)
26+
- Vite+ checks (Oxlint and Oxfmt)
2727
- GraphQL generator
2828
- TypeScript and JavaScript flavors
2929
- Tailwind CSS v4 (via Vite)
@@ -67,7 +67,7 @@ npm install
6767
npm run dev
6868

6969
# Run code quality checks before committing
70-
npm run biome:fix
70+
npm run check:fix
7171
npm run typecheck
7272

7373
# Build for production
@@ -345,10 +345,9 @@ app/
345345
└── weaverse/ # Weaverse configuration
346346
347347
Key configuration files:
348-
- biome.json # Code formatting and linting
349348
- codegen.ts # GraphQL code generation
350349
- react-router.config.ts # React Router configuration
351-
- vite.config.ts # Vite bundler configuration
350+
- vite.config.ts # Vite bundler and Vite+ static checks
352351
```
353352

354353
### Development Tools
@@ -362,7 +361,8 @@ Key configuration files:
362361

363362
Before committing, always run:
364363
```bash
365-
npm run biome:fix # Fix linting/formatting
364+
npm run check # Check lint and formatting
365+
npm run check:fix # Format and apply safe lint fixes
366366
npm run typecheck # Check TypeScript types
367367
npm run codegen # Update GraphQL types
368368
```
@@ -374,7 +374,7 @@ npm run codegen # Update GraphQL types
374374
- [React Router](https://reactrouter.com/)
375375
- [Tailwind CSS v4](https://tailwindcss.com/)
376376
- [Radix UI](https://www.radix-ui.com/)
377-
- [Biome](https://biomejs.dev/)
377+
- [Vite+ checks](https://viteplus.dev/guide/check)
378378

379379
## License
380380

‎app/components/button.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,8 @@ export interface ButtonStyleProps {
7272
}
7373

7474
export interface ButtonProps
75-
extends VariantProps<typeof variants>,
75+
extends
76+
VariantProps<typeof variants>,
7677
Omit<HTMLAttributes<HTMLButtonElement>, "type">,
7778
Partial<ButtonStyleProps> {
7879
type?: "button" | "reset" | "submit";

‎app/components/cart/cart-best-sellers.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ export function CartBestSellers({
7171
}, [load, productsApiPath]);
7272

7373
// Re-measure replaced cards even when the rail's own dimensions stay unchanged.
74-
// biome-ignore lint/correctness/useExhaustiveDependencies: Product and skeleton changes can alter scrollWidth without resizing the rail.
74+
// Product and skeleton changes can alter scrollWidth without resizing the rail.
7575
useEffect(() => {
7676
const rail = railRef.current;
7777
if (layout !== "page" || !rail) {

‎app/components/cart/cart-code-form.tsx‎

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -46,17 +46,17 @@ export function CartCodeForm({
4646
const mutationError = getCartMutationError(fetcher.data, t);
4747
const success = Boolean(
4848
!disabled &&
49-
!requestFailed &&
50-
submittedCode &&
51-
fetcher.data?.cart &&
52-
!mutationError &&
53-
(fetcher.data.codeType === "gift-card"
54-
? fetcher.data.codeApplied === true
55-
: fetcher.data.cart.discountCodes.some(
56-
(discount) =>
57-
discount.applicable &&
58-
discount.code.toLowerCase() === submittedCode.toLowerCase(),
59-
)),
49+
!requestFailed &&
50+
submittedCode &&
51+
fetcher.data?.cart &&
52+
!mutationError &&
53+
(fetcher.data.codeType === "gift-card"
54+
? fetcher.data.codeApplied === true
55+
: fetcher.data.cart.discountCodes.some(
56+
(discount) =>
57+
discount.applicable &&
58+
discount.code.toLowerCase() === submittedCode.toLowerCase(),
59+
)),
6060
);
6161
const showError =
6262
!disabled && submittedCode && !success && (fetcher.data || requestFailed);

‎app/components/cart/cart-summary-actions.tsx‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -202,11 +202,11 @@ export function DiscountDialog({
202202
);
203203
const success = Boolean(
204204
submitted &&
205-
fetcher.data?.cart?.discountCodes?.find(
206-
(discount) =>
207-
discount.code.toLowerCase() === submittedCode.toLowerCase() &&
208-
discount.applicable,
209-
),
205+
fetcher.data?.cart?.discountCodes?.find(
206+
(discount) =>
207+
discount.code.toLowerCase() === submittedCode.toLowerCase() &&
208+
discount.applicable,
209+
),
210210
);
211211
const mutationError = getCartMutationError(fetcher.data, t);
212212
const error = submitted && !success;

‎app/components/cart/store.ts‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -292,12 +292,12 @@ export function canAdjustLineQuantity(
292292
const line = cart?.lines.nodes.find((node) => node.id === lineId);
293293
return Boolean(
294294
line &&
295-
canStageLineQuantity(
296-
state,
297-
lineId,
298-
getNextLineQuantity(line, direction),
299-
cart,
300-
),
295+
canStageLineQuantity(
296+
state,
297+
lineId,
298+
getNextLineQuantity(line, direction),
299+
cart,
300+
),
301301
);
302302
}
303303

‎app/components/heading.tsx‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,7 @@ const variants = cva("heading", {
8686
});
8787

8888
export interface HeadingProps
89-
extends VariantProps<typeof variants>,
90-
VariantProps<typeof fontSizeVariants> {
89+
extends VariantProps<typeof variants>, VariantProps<typeof fontSizeVariants> {
9190
as?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6";
9291
content: string;
9392
color?: string;

0 commit comments

Comments
 (0)