Update README to require spaces (#36595)

This commit is contained in:
Nathan Shively-Sanders 2019-07-02 09:27:47 -07:00 committed by Ryan Cavanaugh
parent 9c9cd26282
commit 6b9b1b15de
2 changed files with 2 additions and 2 deletions

View File

@ -134,7 +134,7 @@ Para un buen paquete de ejemplo, vea [base64-js](https://github.com/DefinitelyTy
#### Errores comunes
* Primero, sigue el consejo del [manual](http://www.typescriptlang.org/docs/handbook/declaration-files/do-s-and-don-ts.html).
* Formatear: Ya sea utilizar todo en tabs, o siempre utiliza 4 espacios.
* Formatear: Utiliza 4 espacios.
* `function sum(nums: number[]): number`: Utiliza `ReadonlyArray` si una función no escribe a sus parámetros.
* `interface Foo { new(): Foo; }`:
Este define el tipo de objeto que esten nuevos. Probablemente quieras `declare class Foo { constructor(); }`.

View File

@ -159,7 +159,7 @@ For a good example package, see [base64-js](https://github.com/DefinitelyTyped/D
#### Common mistakes
* First, follow advice from the [handbook](http://www.typescriptlang.org/docs/handbook/declaration-files/do-s-and-don-ts.html).
* Formatting: Either use all tabs, or always use 4 spaces.
* Formatting: Use 4 spaces. For new code, this is enforced by Prettier.
* `function sum(nums: number[]): number`: Use `ReadonlyArray` if a function does not write to its parameters.
* `interface Foo { new(): Foo; }`:
This defines a type of objects that are new-able. You probably want `declare class Foo { constructor(); }`.