{"version":3,"sources":["../src/configs/v2.ts"],"sourcesContent":["import type { Linter } from \"eslint\";\n\nimport { plugin } from \"../plugin\";\nimport recommended from \"./recommended\";\n\n// The Solid 2.0 config. Sets `settings.solid.version: 2`, which switches\n// version-aware rules (reactivity, imports, no-unknown-namespaces,\n// event-handlers, jsx-no-undef) into strict 2.0 semantics, and enables the\n// 2.0-specific rules. Errors are reserved for near-certain bugs; heuristics\n// stay warnings. This is the config the official templates ship.\nconst v2 = {\n  plugins: {\n    solid: plugin,\n  },\n  languageOptions: {\n    sourceType: \"module\",\n    parserOptions: {\n      ecmaFeatures: {\n        jsx: true,\n      },\n    },\n  },\n  settings: {\n    solid: { version: 2 },\n  },\n  rules: {\n    ...recommended.rules,\n    // 1.x APIs that no longer exist; prescriptive migration guidance\n    \"solid/removed-api\": 2,\n    // 2.0 requires the split createEffect(compute, effect) form\n    \"solid/no-single-arg-create-effect\": 2,\n    // the store read proxy is read-only; mutations go through the setter's draft\n    \"solid/no-store-mutation-outside-setter\": 2,\n    // writes inside memos/compute halves create cycles and throw in 2.0 dev\n    \"solid/no-write-in-pure-computation\": 2,\n    // signals that are never written (or never read) aren't being used as signals\n    \"solid/no-unused-signal\": 1,\n    // uncalled accessors as DOM attributes render stringified functions\n    \"solid/no-accessor-as-prop\": 2,\n    // enumerated attributes (draggable, tristate aria-*) want string tokens;\n    // boolean false removes the attribute, a different state than \"false\"\n    \"solid/no-boolean-enumerated-attribute\": 2,\n    // manual class-string building works but defeats granular class toggling\n    \"solid/prefer-structured-class\": 1,\n    // graduated from style to correctness in 2.0: only camelCase `onClick` is\n    // an event handler; lowercase forms are literal attributes\n    \"solid/event-handlers\": 2,\n    // className/htmlFor pass through as literal attributes the DOM ignores\n    \"solid/no-react-specific-props\": 2,\n    // server functions are core in 2.0; misplaced/ignored \"use server\"\n    // directives and broken module-level directive files are silent failures\n    \"solid/valid-use-server\": 2,\n    // a sync server function returns T during SSR but Promise<T> on the client\n    \"solid/require-async-server-function\": 2,\n    // editor-time mirror of the compiler's closure-capture validation\n    \"solid/no-invalid-server-capture\": 2,\n    // server functions never run where browser globals exist\n    \"solid/no-browser-globals-in-server-function\": 2,\n    // premise no longer exists in 2.0 (rule also self-gates on version)\n    \"solid/no-react-deps\": 0,\n    // anti-advice in 2.0: classList was removed in favor of class objects/arrays\n    \"solid/prefer-classlist\": 0,\n  },\n  // Validate against ESLint's own config type so the export stays assignable\n  // to `defineConfig()` (#233); `satisfies` keeps the precise literal type.\n} satisfies Linter.Config;\n\nexport = v2;\n"],"mappings":";;;;;;;;;AAAA;AAAA;AAEA;AACA,6BAAwB;AAOxB,QAAM,KAAK;AAAA,MACT,SAAS;AAAA,QACP,OAAO;AAAA,MACT;AAAA,MACA,iBAAiB;AAAA,QACf,YAAY;AAAA,QACZ,eAAe;AAAA,UACb,cAAc;AAAA,YACZ,KAAK;AAAA,UACP;AAAA,QACF;AAAA,MACF;AAAA,MACA,UAAU;AAAA,QACR,OAAO,EAAE,SAAS,EAAE;AAAA,MACtB;AAAA,MACA,OAAO;AAAA,QACL,GAAG,mBAAAA,QAAY;AAAA;AAAA,QAEf,qBAAqB;AAAA;AAAA,QAErB,qCAAqC;AAAA;AAAA,QAErC,0CAA0C;AAAA;AAAA,QAE1C,sCAAsC;AAAA;AAAA,QAEtC,0BAA0B;AAAA;AAAA,QAE1B,6BAA6B;AAAA;AAAA;AAAA,QAG7B,yCAAyC;AAAA;AAAA,QAEzC,iCAAiC;AAAA;AAAA;AAAA,QAGjC,wBAAwB;AAAA;AAAA,QAExB,iCAAiC;AAAA;AAAA;AAAA,QAGjC,0BAA0B;AAAA;AAAA,QAE1B,uCAAuC;AAAA;AAAA,QAEvC,mCAAmC;AAAA;AAAA,QAEnC,+CAA+C;AAAA;AAAA,QAE/C,uBAAuB;AAAA;AAAA,QAEvB,0BAA0B;AAAA,MAC5B;AAAA;AAAA;AAAA,IAGF;AAEA,qBAAS;AAAA;AAAA;","names":["recommended"]}