Skip to content

Commit

Permalink
Revert "build: update config patterns, include husky hooks, etc"
Browse files Browse the repository at this point in the history
This reverts commit 6df0d1d.
  • Loading branch information
hobbescodes committed Oct 28, 2023
1 parent 6a14df8 commit 5a2a068
Show file tree
Hide file tree
Showing 22 changed files with 31 additions and 242 deletions.
2 changes: 0 additions & 2 deletions .env.local.template

This file was deleted.

11 changes: 7 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,20 @@ jobs:
name: Handle release 🦋
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 20
node-version: "20.x"
- uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- name: Install dependencies
run: bun i
run: bun install
- name: Create release PR or publish package
id: changesets
uses: changesets/action@v1
with:
publish: bun release
publish: bun run release
title: "feature(release): version packages"
commit: "ci(changesets): version packages"
env:
Expand Down
27 changes: 0 additions & 27 deletions .github/workflows/test.yml

This file was deleted.

7 changes: 1 addition & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
node_modules
build
coverage
node_modules
generated
storybook-static

.env*
!.env*.template
4 changes: 0 additions & 4 deletions .husky/commit-msg

This file was deleted.

4 changes: 0 additions & 4 deletions .husky/pre-commit

This file was deleted.

3 changes: 0 additions & 3 deletions .lintstagedrc

This file was deleted.

Binary file modified bun.lockb
Binary file not shown.
38 changes: 0 additions & 38 deletions commitlint.config.ts

This file was deleted.

18 changes: 3 additions & 15 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,12 @@
"bun"
],
"scripts": {
"prepare": "husky install",
"dev": "panda codegen && concurrently --kill-others -n \"PANDA,STORYBOOK\" -c \"#f13334,#ff4785\" \"bun dev:css\" \"bun storybook\"",
"dev:css": "panda --watch",
"prepare": "panda codegen",
"dev": "concurrently --kill-others -n \"BUILD,STORYBOOK\" -c \"#f13334,#ff4785\" \"bun run build --watch\" \"bun run storybook\"",
"build": "panda codegen && tsup",
"format": "prettier . --write",
"lint": "eslint --ext .js,.jsx,.ts,.tsx src",
"test": "test-storybook",
"test:coverage": "bun run test --coverage",
"test:ci": "concurrently --kill-others -s first -n \"STORYBOOK,TEST\" -c \"#ff4785,#45ba4b\" \"http-server storybook-static --port 6006 --silent\" \"wait-on tcp:6006 && bun test:coverage --ci\"",
"test:watch": "bun run test --watch",
"storybook": "storybook dev --quiet --no-open -p 6006",
"storybook:build": "panda codegen && storybook build",
"release": "bun run build && changeset publish"
Expand All @@ -55,12 +51,8 @@
"@ark-ui/react": "^0.15.0",
"@changesets/changelog-github": "^0.4.8",
"@changesets/cli": "^2.26.2",
"@commitlint/cli": "^18.2.0",
"@commitlint/config-conventional": "^18.1.0",
"@commitlint/types": "^18.1.0",
"@omnidev/knit": "^0.1.2",
"@pandacss/dev": "^0.17.3",
"@pandacss/types": "^0.17.3",
"@pandacss/dev": "^0.16.0",
"@storybook/addon-a11y": "^7.4.6",
"@storybook/addon-essentials": "^7.4.6",
"@storybook/addon-interactions": "^7.4.6",
Expand All @@ -79,7 +71,6 @@
"@typescript-eslint/eslint-plugin": "^6.7.5",
"@typescript-eslint/parser": "^6.7.5",
"concurrently": "^8.2.1",
"dotenv-cli": "^7.3.0",
"eslint": "^8.51.0",
"eslint-config-prettier": "^9.0.0",
"eslint-import-resolver-typescript": "^3.6.1",
Expand All @@ -92,9 +83,6 @@
"eslint-plugin-testing-library": "^6.1.0",
"eslint-plugin-typescript-sort-keys": "^3.1.0",
"eslint-plugin-unused-imports": "^3.0.0",
"http-server": "^14.1.1",
"husky": "^8.0.3",
"lint-staged": "^15.0.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-icons": "^4.11.0",
Expand Down
21 changes: 3 additions & 18 deletions panda.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
import { defineConfig } from "@pandacss/dev";

import { PREGENERATE_STATIC_CSS } from "lib/config";
import { recipes, slotRecipes } from "lib/panda";
import tigrisPreset from "lib/panda/tigris.preset";
import { mapArrayToObject } from "lib/util";

const recipeKeys = Object.keys(recipes);
const slotRecipeKeys = Object.keys(slotRecipes);

/**
* 🐼 Panda configuration.
Expand All @@ -16,19 +10,10 @@ const pandaConfig = defineConfig({
preflight: true,
include: ["src/**/*.{ts,tsx,mdx}"],
outdir: "src/generated/panda",
presets: ["@pandacss/preset-base", tigrisPreset],
jsxFramework: "react",
presets: ["@pandacss/dev/presets", tigrisPreset],
// set JSX factory name
jsxFactory: "panda",
staticCss: PREGENERATE_STATIC_CSS
? {
// pregenerate recipe styles; allow Storybook stories to properly use `args` without needing to hint the extractor with `render` or other workarounds like `{fn}.raw`
// TODO PurgeCSS (https://panda-css.com/docs/guides/static#removing-unused-css)
recipes: {
...mapArrayToObject(recipeKeys, ["*"]),
...mapArrayToObject(slotRecipeKeys, ["*"]),
},
}
: {},
jsxFramework: "react",
});

export default pandaConfig;
11 changes: 0 additions & 11 deletions src/lib/config/app.config.ts

This file was deleted.

4 changes: 0 additions & 4 deletions src/lib/config/env.config.ts

This file was deleted.

2 changes: 0 additions & 2 deletions src/lib/config/index.ts

This file was deleted.

2 changes: 1 addition & 1 deletion src/lib/panda/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ export { default as animations } from "./animations";
export { default as colors } from "./colors";
export { default as easings } from "./easings";
export { default as keyframes } from "./keyframes";
export { recipes, slotRecipes } from "./recipes";
export { slotRecipes } from "./recipes";
export { default as semanticTokens } from "./semanticTokens";
export { default as zIndex } from "./zIndex";
2 changes: 0 additions & 2 deletions src/lib/panda/recipes.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import { modalRecipe } from "../../components/Modal/Modal.recipe";

export const recipes = {};

export const slotRecipes = {
modal: modalRecipe,
};
1 change: 0 additions & 1 deletion src/lib/util/index.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
export { default as mapArrayToObject } from "./mapArrayToObject";
export { default as sleep } from "./sleep";
19 changes: 0 additions & 19 deletions src/lib/util/mapArrayToObject.ts

This file was deleted.

13 changes: 0 additions & 13 deletions test-runner-jest.config.js

This file was deleted.

16 changes: 0 additions & 16 deletions tsconfig.build.json

This file was deleted.

26 changes: 6 additions & 20 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,7 @@
"forceConsistentCasingInFileNames": true,
"isolatedModules": true,
"jsx": "react-jsx",
"lib": [
"dom",
"esnext"
],
"lib": ["dom", "esnext"],
"module": "esnext",
"moduleResolution": "node",
"noEmit": true,
Expand All @@ -19,20 +16,9 @@
"sourceMap": true,
"strict": true,
"target": "esnext",
"typeRoots": [
"generated/panda"
]
"typeRoots": ["generated/panda", "node_modules/@types"],
"outDir": "build"
},
"include": [
"src",
"*.config.ts",
"*.config.cjs",
".storybook/**/*.ts",
".storybook/**/*.tsx",
"test-runner-jest.config.js"
],
"exclude": [
"**/node_modules",
"src/generated"
]
}
"include": ["src", "*.config.ts", "*.config.cjs", ".storybook/**/*.ts"],
"exclude": ["node_modules"]
}
Loading

0 comments on commit 5a2a068

Please sign in to comment.