Replace "Midget" with "Widget" in example words

Word "Midget" can be offensive and shouldn't be included as an example in educational materials. Replaced with "Widget" for better consistency/inclusiveness. https://www.lpaonline.org/the-m-word
This commit is contained in:
Jose E. Pimentel 2019-08-13 09:54:35 -04:00 committed by GitHub
parent 763aba5075
commit 4856c06dee
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -364,8 +364,8 @@ alert( "Hello".includes("Bye") ); // false
The optional second argument of `str.includes` is the position to start searching from:
```js run
alert( "Midget".includes("id") ); // true
alert( "Midget".includes("id", 3) ); // false, from position 3 there is no "id"
alert( "Widget".includes("id") ); // true
alert( "Widget".includes("id", 3) ); // false, from position 3 there is no "id"
```
The methods [str.startsWith](mdn:js/String/startsWith) and [str.endsWith](mdn:js/String/endsWith) do exactly what they say: