forcedotcom / forcedotcom/code-analyzer

[BUG][code-analyzer] SRR checks done for LWC which are non lightning__ServerRenderable or lightning__ServerRenderableWithHydration

Abierto
#2,049 1 comentario 0 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
TypeScript
Estrellas
240
Forks
52
Merge medio
1 d 23 h
PR fusionados (30 d)
5

Descripción

### Have you tried to resolve this issue yourself first?

- [x] I confirm I have gone through the above steps and still have an issue to report.

### Bug Description

Create a simple LWC, with

`import hasDelegatedAdmin from '@salesforce/customPermission/DelegatedAdmin';`
or any

- @salesforce/user/*
- @salesforce/userPermission/*
- @salesforce/customPermission/*

Run the code analyser eslint scan, the error show up.
https://github.com/salesforce/eslint-plugin-lwc/blob/v3.5.0/docs/rules/ssr/ssr-no-static-imports-of-user-specific-scoped-modules.md
The LWC component is neither marked with lightning__ServerRenderable nor lightning__ServerRenderableWithHydration

### Output / Logs

```shell

```

### Steps To Reproduce

Check Description.

### Expected Behavior

The error should happen only for LWCs components with lightning__ServerRenderable nor lightning__ServerRenderableWithHydration

### Operating System

Any

### Salesforce CLI Version

@salesforce/cli/2.136.8 darwin-arm64 node-v22.22.2

### Code Analyzer Plugin (code-analyzer) Version

code-analyzer 5.12.0 (5.12.0)

### Node Version

_No response_

### Java Version

_No response_

### Python Version

_No response_

### Additional Context (Screenshots, Files, etc)

_No response_

### Workaround

Suppress or lower the error to warning.

### Urgency

High

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Comienza con docs/rules/ssr/ssr-no-static-imports-of-user-specific-scoped-modules.md y reproduce el escaneo de eslint usando las importaciones de LWC indicadas en el informe. Verifica que el error ocurra únicamente en componentes marcados con lightning__ServerRenderable o lightning__ServerRenderableWithHydration, y confirma el comportamiento corregido con una prueba de regresión.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
typescript
Área
tooling
Tipo de issue
Error
Dificultad
3/5
Tiempo estimado
1-2 días
Estado de actividad
Tranquilo
Claridad
Bastante claro
Aptitud para principiantes
48/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.