mirror of
https://github.com/mulgadc/spinifex.git
synced 2026-10-15 09:01:31 +00:00
chore: enable no-array-index-key rule
This commit is contained in:
@@ -45,6 +45,7 @@ export default defineConfig({
|
||||
"error",
|
||||
{ namedComponents: "function-declaration" },
|
||||
],
|
||||
"react/no-array-index-key": "error",
|
||||
"react/jsx-handler-names": "off",
|
||||
"react/todo": "off",
|
||||
"react-you-might-not-need-an-effect/no-event-handler": "error",
|
||||
|
||||
@@ -127,6 +127,7 @@ export function CliCommandPanel({ commands }: CliCommandPanelProps) {
|
||||
<pre className="font-mono text-xs/relaxed">
|
||||
<code>
|
||||
{cmd.parts.map((part, j) => (
|
||||
// oxlint-disable-next-line no-array-index-key -- positional tokens of one command, never reordered
|
||||
<span key={j} className={partStyles[part.type]}>
|
||||
{part.value}
|
||||
</span>
|
||||
|
||||
+1
@@ -353,6 +353,7 @@ export function CreateLoadBalancerPage() {
|
||||
</p>
|
||||
<ul className="mt-1 list-inside list-disc text-xs text-destructive">
|
||||
{wizardResult.created.map((r, i) => (
|
||||
// oxlint-disable-next-line no-array-index-key -- static failure summary, never reordered or filtered
|
||||
<li key={i}>
|
||||
{r.type}: {r.id ?? "(created)"}
|
||||
</li>
|
||||
|
||||
@@ -162,6 +162,7 @@ function CreateVpc() {
|
||||
</p>
|
||||
<ul className="mt-1 list-inside list-disc text-xs text-destructive">
|
||||
{wizardResult.created.map((r, i) => (
|
||||
// oxlint-disable-next-line no-array-index-key -- static failure summary, never reordered or filtered
|
||||
<li key={i}>
|
||||
{r.type}: {r.id}
|
||||
</li>
|
||||
|
||||
+1
@@ -381,6 +381,7 @@ export function CreateClusterPage() {
|
||||
<span className="font-mono">0.0.0.0/0</span>.
|
||||
</p>
|
||||
{publicCidrs.map((cidr, index) => (
|
||||
// oxlint-disable-next-line no-array-index-key -- controlled inputs; a stable key needs publicAccessCidrs off string[]
|
||||
<div className="flex items-center gap-2" key={index}>
|
||||
<Input
|
||||
aria-label={`Public access CIDR ${index + 1}`}
|
||||
|
||||
Reference in New Issue
Block a user