Skip to content

Commit

Permalink
Merge branch 'master' into create_new_react_app
Browse files Browse the repository at this point in the history
  • Loading branch information
arshadkazmi42 committed Nov 10, 2019
2 parents 6820594 + 588587a commit c339b69
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 14 deletions.
5 changes: 5 additions & 0 deletions content/community/conferences.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@ April 23 - 24, 2020 in Kraków, Poland

[Website](http://appjs.co/react) - [Twitter](https://twitter.com/appjsconf)

### React Day Bangalore 2020 {#react-day-bangalore-2020}
April 25, 2020 in Bangalore, India

[Website](https://reactday.in) - [Twitter](https://twitter.com/ReactDayIn)

### render(ATL) 2020 {#render-atlanta-2020}
May 4-6, 2020. Atlanta, GA, USA.

Expand Down
10 changes: 10 additions & 0 deletions content/community/meetups.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,14 @@ Do you have a local React.js meetup? Add it here! (Please keep the list alphabet
## Brazil {#brazil}
* [Belo Horizonte](https://www.meetup.com/reactbh/)
* [Curitiba](https://www.meetup.com/pt-br/ReactJS-CWB/)
* [Florianópolis](https://www.meetup.com/pt-br/ReactJS-Floripa/)
* [Goiânia](https://www.meetup.com/pt-br/React-Goiania/)
* [Joinville](https://www.meetup.com/pt-BR/React-Joinville/)
* [Juiz de Fora](https://www.meetup.com/pt-br/React-Juiz-de-Fora/)
* [Maringá](https://www.meetup.com/pt-BR/React-Maringa/)
* [Porto Alegre](https://www.meetup.com/pt-BR/React-Porto-Alegre/)
* [Rio de Janeiro](https://www.meetup.com/pt-BR/React-Rio-de-Janeiro/)
* [Salvador](https://www.meetup.com/pt-BR/ReactSSA)
* [São Paulo](https://www.meetup.com/pt-BR/ReactJS-SP/)
* [Vila Velha](https://www.meetup.com/pt-BR/React-ES/)

Expand Down Expand Up @@ -75,6 +81,9 @@ Do you have a local React.js meetup? Add it here! (Please keep the list alphabet
* [Delhi NCR](https://www.meetup.com/React-Delhi-NCR/)
* [Jaipur](https://www.meetup.com/JaipurJS-Developer-Meetup/)

## Indonesia {#indonesia}
* [Indonesia](https://www.meetup.com/reactindonesia/)

## Ireland {#ireland}
* [Dublin](https://www.meetup.com/ReactJS-Dublin/)

Expand Down Expand Up @@ -137,6 +146,7 @@ Do you have a local React.js meetup? Add it here! (Please keep the list alphabet
* [Chicago, IL - ReactJS](https://www.meetup.com/React-Chicago/)
* [Columbus, OH - ReactJS](https://www.meetup.com/ReactJS-Columbus-meetup/)
* [Dallas, TX - ReactJS](https://www.meetup.com/ReactDallas/)
* [Detroit, MI - Detroit React User Group](https://www.meetup.com/Detroit-React-User-Group/)
* [Irvine, CA - ReactJS](https://www.meetup.com/ReactJS-OC/)
* [Kansas City, MO - ReactJS](https://www.meetup.com/Kansas-City-React-Meetup/)
* [Las Vegas, NV - ReactJS](https://www.meetup.com/ReactVegas/)
Expand Down
24 changes: 12 additions & 12 deletions content/docs/addons-shallow-renderer.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ import ShallowRenderer from 'react-test-renderer/shallow'; // ES6
var ShallowRenderer = require('react-test-renderer/shallow'); // ES5 with npm
```

## Overview {#overview}
## ओवरव्यू {#overview}

When writing unit tests for React, shallow rendering can be helpful. Shallow rendering lets you render a component "one level deep" and assert facts about what its render method returns, without worrying about the behavior of child components, which are not instantiated or rendered. This does not require a DOM.
React के लिए यूनिट टेस्ट लिखते समय शैलो रेंडरिंग काफ़ी उपयोगी हो सकती है। शैलो रेंडरिंग आपको एक कौम्पोनॅन्ट को "एक स्तर गहरा" रेंडर करने देता है और रेंडर मेथड जो रिटर्न कर रहा है उसको अस्सर्ट कर सकते हैं कि इस कौम्पोनॅन्ट का रेंडर मेथड क्या return करेगा, child कौम्पोनॅन्टस के व्यव्हार की चिंता किये बिना, जो की instantiate या रेंडर नहीं होते। इसमें DOM की आवश्यकता नहीं होती है।

For example, if you have the following component:
उदहारण के लिए, अगर आपके पास निम्नलिखित कौम्पोनॅन्ट है:

```javascript
function MyComponent() {
Expand All @@ -30,7 +30,7 @@ function MyComponent() {
}
```

Then you can assert:
तब आप अस्सर्ट कर सकते हैं:

```javascript
import ShallowRenderer from 'react-test-renderer/shallow';
Expand All @@ -47,22 +47,22 @@ expect(result.props.children).toEqual([
]);
```

Shallow testing currently has some limitations, namely not supporting refs.
वर्तमान में शैलो टेस्टिंग की कुछ सीमाएँ हैं, नामतः ये refs के साथ काम नहीं करता।

> Note:
> टिप्पणी:
>
> We also recommend checking out Enzyme's [Shallow Rendering API](https://airbnb.io/enzyme/docs/api/shallow.html). It provides a nicer higher-level API over the same functionality.
> हम Enzyme के [शैलो रेंडरिंग API](https://airbnb.io/enzyme/docs/api/shallow.html) का भी परीक्षण करने की भी सलाह देते हैं। यह उसी फंक्शनलिटी पर एक और अच्छे स्तर की API देता है।
## Reference {#reference}
## संदर्भ {#reference}

### `shallowRenderer.render()` {#shallowrendererrender}

You can think of the shallowRenderer as a "place" to render the component you're testing, and from which you can extract the component's output.
आप जिस कौम्पोनॅन्ट का परीक्षण कर रहे हैं, shallowRenderer को आप उसे रेंडर करने के एक "स्थान" की तरह सोच सकते हैं, और इससे आप कौम्पोनॅन्ट के आउटपुट को निकाल सकते हैं।

`shallowRenderer.render()` is similar to [`ReactDOM.render()`](/docs/react-dom.html#render) but it doesn't require DOM and only renders a single level deep. This means you can test components isolated from how their children are implemented.
`shallowRenderer.render()` [`ReactDOM.render()`](/docs/react-dom.html#render) के समान ही है लेकिन इसे DOM की आवश्यकता नहीं है और यह केवल एक स्तर गहराई तक ही रेंडर करता है। इसका मतलब आप कौम्पोनॅन्टस का परिक्षण उनके children के लागू होने के तरीके से अलग रखकर कर सकते हैं।

### `shallowRenderer.getRenderOutput()` {#shallowrenderergetrenderoutput}

After `shallowRenderer.render()` has been called, you can use `shallowRenderer.getRenderOutput()` to get the shallowly rendered output.
`shallowRenderer.render()` के call हो जाने के बाद आप शैलो रेंडर हुए आउटपुट को पाने के लिए `shallowRenderer.getRenderOutput()` का इस्तेमाल कर सकते हैं।

You can then begin to assert facts about the output.
तब आप आउटपुट के बारे में तथ्यों को अस्सर्ट करना शुरू कर सकते हैं।
2 changes: 1 addition & 1 deletion content/docs/concurrent-mode-suspense.md
Original file line number Diff line number Diff line change
Expand Up @@ -668,7 +668,7 @@ Suspense answers some questions, but it also poses new questions of its own:

* If some component "suspends", does the app freeze? How to avoid this?
* What if we want to show a spinner in a different place than "above" the component in a tree?
* If we intentionally *want* to show an inconsistent UI for a small period time, can we do that?
* If we intentionally *want* to show an inconsistent UI for a small period of time, can we do that?
* Instead of showing a spinner, can we add a visual effect like "greying out" the current screen?
* Why does our [last Suspense example](https://codesandbox.io/s/infallible-feather-xjtbu) log a warning when clicking the "Next" button?

Expand Down
2 changes: 2 additions & 0 deletions content/versions.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
- title: '16.11'
changelog: https://github.com/facebook/react/blob/master/CHANGELOG.md#16110-october-22-2019
- title: '16.10.2'
changelog: https://github.com/facebook/react/blob/master/CHANGELOG.md#16102-october-3-2019
- title: '16.10.1'
Expand Down
2 changes: 1 addition & 1 deletion src/site-constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
// NOTE: We can't just use `location.toString()` because when we are rendering
// the SSR part in node.js we won't have a proper location.
const urlRoot = 'https://reactjs.org';
const version = '16.10.2';
const version = '16.11.0';
const babelURL = 'https://unpkg.com/babel-standalone@6.26.0/babel.min.js';

export {babelURL, urlRoot, version};

0 comments on commit c339b69

Please sign in to comment.