[RFC]: rename primitive array `assert` packages
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- javascript
- Área
- developer-experience, tooling
Línea de trabajo
Empieza revisando los nombres de los paquetes de primitive-array enumerados y buscando sus usos en el proyecto. Considera la convención -of-, el trabajo de migración, las implicaciones para JSDoc y la deprecación en npm y GitHub. Se considerará terminado cuando se haya acordado el enfoque de nomenclatura y se haya definido el alcance de la migración resultante.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Description
This RFC proposes renaming the following packages:
-
is-array-array=>is-array-of-arrays- alias:
isArrayArray=>isArrayOfArrays
- alias:
-
is-boolean-array=>is-array-of-booleans- alias:
isBooleanArray=>isArrayOfBooleans
- alias:
-
is-date-object-array=>is-array-of-date-objects- alias:
isDataObjectArray=>isArrayOfDateObjects
- alias:
-
is-function-array=>is-array-of-functions- alias:
isFunctionArray=>isArrayOfFunctions
- alias:
-
is-integer-array=>is-array-of-integers- alias:
isIntegerArray=>isArrayOfIntegers
- alias:
-
is-nan-array=>is-array-of-nans- alias:
isNaNArray=>isArrayOfNaNs
- alias:
-
is-negative-integer-array=>is-array-of-negative-integers- alias:
isNegativeIntegerArray=>isArrayOfNegativeIntegers
- alias:
-
is-negative-number-array=>is-array-of-negative-numbers- alias:
isNegativeNumberArray=>isArrayOfNegativeNumbers
- alias:
-
is-nonnegative-integer-array=>is-array-of-nonnegative-integers- alias:
isNonNegativeIntegerArray=>isArrayOfNonNegativeIntegers
- alias:
-
is-nonnegative-number-array=>is-array-of-nonnegative-numbers- alias:
isNonNegativeNumberArray=>isArrayOfNonNegativeNumbers
- alias:
-
is-nonpositive-integer-array=>is-array-of-nonpositive-integers- alias:
isNonPositiveIntegerArray=>isArrayOfNonPositiveIntegers
- alias:
-
is-nonpositive-number-array=>is-array-of-nonpositive-numbers- alias:
isNonPositiveNumberArray=>isArrayOfNonPositiveNumbers
- alias:
-
is-null-array=>is-array-of-nulls- alias:
isNullArray=>isArrayOfNulls
- alias:
-
is-object-array=>is-array-of-objects- alias:
isObjectArray=>isArrayOfObjects
- alias:
-
is-plain-object-array=>is-array-of-plain-objects- alias:
isPlainObjectArray=>isArrayOfPlainObjects
- alias:
-
is-positive-integer-array=>is-array-of-positive-integers- alias:
isPositiveIntegerArray=>isArrayOfPositiveIntegers
- alias:
-
is-positive-number-array=>is-array-of-positive-numbers- alias:
isPositiveNumberArray=>isArrayOfPositiveNumbers
- alias:
-
is-primitive-array=>is-array-of-primitives- alias:
isPrimitiveArray=>isArrayOfPrimitives
- alias:
-
is-probability-array=>is-array-of-probabilities- alias:
isProbabilityArray=>isArrayOfProbabilities
- alias:
-
is-safe-integer-array=>is-array-of-safe-integers- alias:
isSafeIntegerArray=>isArrayOfSafeIntegers
- alias:
-
is-string-array=>is-array-of-strings- alias:
isStringArray=>isArrayOfStrings
- alias:
-
is-symbol-array=>is-array-of-symbols- alias:
isSymbolArray=>isArrayOfSymbols
- alias:
Rationale
As the project has grown and started accumulating custom array types (e.g., BooleanArray, Complex128Array, Int64Array, etc), older naming conventions are beginning to conflict with continued project evolution.
The most immediate example is is-booleanarray and is-boolean-array. Which is the assertion package for BooleanArray and which is for an array of booleans (e.g., [ true, false, true ])? It is not obvious which is which and can be a point of confusion.
This RFC proposes migrating existing packages which refer explicitly to the contents of a collection and not to a particular instance type to a new naming convention which more explicitly indicates what the package is intended to test for and should avoid conflicts with any future array types (e.g., StringArray, ObjectArray, etc).
Notes
Packages which are not included in the proposed migration:
is-between-arrayis-falsy-arrayis-finite-arrayis-truthy-arrayis-unity-probability-array
These packages were considered to be (a) highly unlikely to conflict with future specialized array constructors and (b) not have good readability with the proposed naming convention (e.g., isArrayOfBetween).
Related Issues
N/A
Questions
-
The proposed changes will create quite a bit of churn throughout the project as many of these packages are heavily used. The question is then whether the churn is worth it. In my opinion, it is, but others may have different opinions.
-
Is there a better naming convention than the
*-of-*proposal above? -
JSDoc conventions are intentionally left out (e.g.,
@param {NonNegativeIntegerArray}). IMO, these also need to be migrated in order to avoid confusion with class instances, but I think this is something which can be addressed in a separate RFC, as it is not clear what the naming convention should be (e.g.,Array<integer>,Array<nonnegative_integer>, something else?).
Other
cc @Planeshifter as we previously discussed the confusion between is-boolean-array and is-booleanarray. This is my attempt to resolve that confusion.
Should this RFC be accepted and completed, we'll want to deprecate the existing packages and have them point to the new packages on both npm and GitHub.
Checklist
- I have read and understood the Code of Conduct.
- Searched for existing issues and pull requests.
- The issue name begins with
RFC:.
- Lenguaje dominante
- JavaScript
- Estrellas
- 6k
- Forks
- 1.3k
- Merge medio
- 1 d 9 h
- PR fusionados (30 d)
- 607
Preparar el entorno
Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de stdlib-js/stdlib
-
`@stdlib/string/base/percent-encode` produces malformed encoding and silently drops charactersAbiertoBug
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
stdlib-js/stdlib#15595 · 6 comentarios ·
Los mantenedores suelen responder en 1 día
-
[Bug]: kumaraswamy/kurtosis returns non-excess kurtosis (missing −3)Posiblemente ocupada @Planeshifter la tomó hace 4 días. AbiertoBug Statistics
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
stdlib-js/stdlib#15461 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
[Bug]: rayleigh/mgf returns wrong values due to misplaced parenthesisPosiblemente ocupada @anandkaranubc la tomó hace 6 días. AbiertoBug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
stdlib-js/stdlib#15456 · 6 comentarios · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
stdlib-js/stdlib#15193 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Fix JavaScript lint errorsAbiertoGood First Issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
stdlib-js/stdlib#14759 · 3 comentarios ·
Los mantenedores suelen responder en 1 día
Todos los issues de stdlib-js/stdlib
Issues similares
-
Daemon delete dialog: "Remove all ExApps" checkbox and `removeExApps` parameter have no effectAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
Los mantenedores suelen responder en 3 días
-
Add: Atlas TVAbiertochannels:add check:passed
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 4 días
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
jaegertracing/jaeger-ui#4547 · 3 comentarios ·
Los mantenedores suelen responder en 1 día
-
feedback simulation workshop
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
githubnext/gh-aw-workshop#4090 ·
Los mantenedores suelen responder en 1 día
-
bug deck: add to staging level: missing p-feature: Manage Submissions p-feature: Submissions and process priority: MUST HAVE ready for dev lead role: missing size: missing time sensitive
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
hackforla/tdm-calculator#3581 ·
Los mantenedores suelen responder en 2 días