SolidJS + Husky + lint-staged
Git pre-commit hook that lints and formats staged files. This page shows exactly what pickstack adds to a SolidJS project for Husky + lint-staged: the packages, the new files and the changes to existing ones. Every combination is installed, built, linted and tested in CI.
$ npm create pickstack@latest my-app -- --framework solid --modules eslint,husky-lint-staged --yesCustomize in the configurator
Packages it adds
| Package | Version | Type |
|---|---|---|
@eslint/js | ^10.0.1 | dev |
eslint | ^10.15.0 | dev |
eslint-plugin-solid | ^0.20.1 | dev |
globals | ^17.14.0 | dev |
husky | ^9.1.7 | dev |
lint-staged | ^17.6.2 | dev |
typescript-eslint | ^8.74.0 | dev |
New files
lint-staged
import js from "@eslint/js";
import { defineConfig, globalIgnores } from "eslint/config";
import solid from "eslint-plugin-solid/configs/typescript";
import globals from "globals";
import tseslint from "typescript-eslint";
export default defineConfig([
globalIgnores(["dist"]),
{
files: ["**/*.{ts,tsx}"],
extends: [js.configs.recommended, tseslint.configs.recommended, solid],
languageOptions: {
globals: globals.browser,
},
},
]);
Project files
.gitignore.husky/pre-commitREADME.mdeslint.config.jsindex.htmlpackage.jsonsrc/App.tsxsrc/components/Counter.tsxsrc/index.csssrc/index.tsxtsconfig.app.jsontsconfig.jsontsconfig.node.jsonvite.config.ts