You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/content/learn/tutorial-tic-tac-toe.md
+32-31Lines changed: 32 additions & 31 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,31 +1,31 @@
1
1
---
2
-
title: 'Tutorial: Tic-Tac-Toe'
2
+
title: 'টিউটোরিয়াল: টিক-ট্যাক-টো'
3
3
---
4
4
5
5
<Intro>
6
6
7
-
You will build a small tic-tac-toe game during this tutorial. This tutorial does not assume any existing React knowledge. The techniques you'll learn in the tutorial are fundamental to building any React app, and fully understanding it will give you a deep understanding of React.
7
+
এই টিউটোরিয়ালের সময় আপনি একটি ছোট টিক-ট্যাক-টো গেম তৈরি করবেন। এই টিউটোরিয়ালটি কোন পূর্বের React জ্ঞান অনুমান করে না। টিউটোরিয়ালে আপনি যে কৌশলগুলি শিখবেন তা যেকোন React অ্যাপ তৈরির জন্য অপরিহার্য, এবং এটি সম্পূর্ণরূপে বোঝা আপনাকে React সম্পর্কে গভীর ধারণা দেবে।
8
8
9
9
</Intro>
10
10
11
11
<Note>
12
12
13
-
This tutorial is designed for people who prefer to**learn by doing**and want to quickly try making something tangible. If you prefer learning each concept step by step, start with [Describing the UI.](/learn/describing-the-ui)
13
+
এই টিউটোরিয়ালটি এমন লোকদের জন্য ডিজাইন করা হয়েছে যারা**কাজ করে শিখতে**পছন্দ করেন এবং দ্রুত কিছু তৈরি করার চেষ্টা করতে চান। আপনি যদি প্রতিটি ধারণা ধাপে ধাপে শিখতে পছন্দ করেন, তাহলে [Describing the UI.](/learn/describing-the-ui) দিয়ে শুরু করুন।
14
14
15
15
</Note>
16
16
17
-
The tutorial is divided into several sections:
17
+
টিউটোরিয়ালটি কয়েকটি বিভাগে বিভক্ত:
18
18
19
-
-[Setup for the tutorial](#setup-for-the-tutorial)will give you **a starting point**to follow the tutorial.
20
-
-[Overview](#overview)will teach you **the fundamentals**of React: components, props, and state.
21
-
-[Completing the game](#completing-the-game)will teach you**the most common techniques**in React development.
22
-
-[Adding time travel](#adding-time-travel)will give you **a deeper insight**into the unique strengths of React.
19
+
-[টিউটোরিয়ালের জন্য সেটআপ](#setup-for-the-tutorial)আপনাকে টিউটোরিয়ালটি অনুসরণ করার জন্য **একটি শুরুর ধাপ**দেবে।
20
+
-[সংক্ষিপ্ত বিবরণ](#overview)আপনাকে React-এর **মৌলিক বিষয়গুলি**যথা: components, props এবং state সম্পর্কে শেখাবে|
21
+
-[গেমটি সম্পূর্ণ করা](#completing-the-game)আপনাকে React Development-এর**সবচেয়ে সাধারণ কৌশলগুলি**শেখাবে।
22
+
-[সময়ে ভ্রমন্ করা](#adding-time-travel)আপনাকে React-এর অনন্য শক্তিসমূহ সম্পর্কে **গভীর দৃষ্টি**দেবে ।
23
23
24
-
### What are you building? {/*what-are-you-building*/}
24
+
### আপনি কি বানাবেন? {/*what-are-you-building*/}
25
25
26
-
In this tutorial, you'll build an interactive tic-tac-toe game with React.
26
+
এই টিউটোরিয়ালে, আপনি React-এর সাহায্যে একটি ইন্টারেক্টিভ টিক-ট্যাক-টো গেম তৈরি করবেন।
27
27
28
-
You can see what it will look like when you're finished here:
28
+
গেমটির অন্তিম রূপ আপনি এখানে দেখতে পাচ্ছেন:
29
29
30
30
<Sandpack>
31
31
@@ -194,15 +194,15 @@ body {
194
194
195
195
</Sandpack>
196
196
197
-
If the code doesn't make sense to you yet, or if you are unfamiliar with the code's syntax, don't worry! The goal of this tutorial is to help you understand React and its syntax.
197
+
যদি কোডটি এখনও আপনার কাছে বোধগম্য না হয়, বা আপনি যদি কোডের syntax সাথে অপরিচিত হন তবে চিন্তা করবেন না! এই টিউটোরিয়ালের লক্ষ্য হল আপনাকে React এবং এর syntax বুঝতে সাহায্য করা।
198
198
199
-
We recommend that you check out the tic-tac-toe game above before continuing with the tutorial. One of the features that you'll notice is that there is a numbered list to the right of the game's board. This list gives you a history of all of the moves that have occurred in the game, and it is updated as the game progresses.
199
+
আমরা সুপারিশ করছি যে আপনি টিউটোরিয়ালটি শুরু করার আগে উপরের টিক-ট্যাক-টো গেমটি দেখুন। আপনি যে বৈশিষ্ট্যগুলি লক্ষ্য করবেন তাদের মধ্যে একটি হল গেমের বোর্ডের ডানদিকে একটি সংখ্যাযুক্ত তালিকা রয়েছে। এই তালিকাটি আপনাকে গেমটিতে ঘটে যাওয়া সমস্ত পদক্ষেপের একটি ইতিহাস দেয় এবং গেমটি অগ্রসর হওয়ার সাথে সাথে এটি update হয়।
200
200
201
-
Once you've played around with the finished tic-tac-toe game, keep scrolling. You'll start with a simpler template in this tutorial. Our next step is to set you up so that you can start building the game.
201
+
আপনার একবার টিকে-টাক-টো গেমটি খেলা হয় গেলে আপনি পরবর্তী পর্যায়ে স্ক্রল করুন । আপনি এই টিউটোরিয়াল একটি সহজ টেমপ্লেট দিয়ে শুরু করবেন। আমাদের পরবর্তী পদক্ষেপ হল আপনাকে সেট আপ করা যাতে আপনি গেমটি তৈরি করা শুরু করতে পারেন।
202
202
203
-
## Setup for the tutorial {/*setup-for-the-tutorial*/}
203
+
## টিউটোরিয়ালের জন্য সেটআপ {/*setup-for-the-tutorial*/}
204
204
205
-
In the live code editor below, click **Fork** in the top-right corner to open the editor in a new tab using the website CodeSandbox. CodeSandbox lets you write code in your browser and preview how your users will see the app you've created. The new tab should display an empty square and the starter code for this tutorial.
205
+
নীচের লাইভ কোড এডিটরে, CodeSandbox ওয়েবসাইট ব্যবহার করে সম্পাদকটিকে একটি নতুন ট্যাবে খুলতে উপরের-ডানদিকের কোণায় **Fork**-এ ক্লিক করুন। CodeSandbox আপনাকে আপনার Browser-এ কোড লিখতে দেয় এবং আপনার তৈরি করা অ্যাপটি কীভাবে দেখাবে তার preview দেখতে দেয়। নতুন ট্যাবে এই টিউটোরিয়ালের জন্য একটি খালি বর্গক্ষেত্র এবং starter code প্রদর্শন করা উচিত।
206
206
207
207
<Sandpack>
208
208
@@ -261,33 +261,34 @@ body {
261
261
262
262
<Note>
263
263
264
-
You can also follow this tutorial using your local development environment. To do this, you need to:
264
+
আপনি এই টিউটোরিয়ালটি নিজের local development environment ব্যবহার করে ও follow করতে পারেন। এর জন্য আপনাকে নিচের steps-গুলো follow করতে হবে:
265
265
266
266
1. Install [Node.js](https://nodejs.org/en/)
267
267
1. In the CodeSandbox tab you opened earlier, press the top-left corner button to open the menu, and then choose **Download Sandbox** in that menu to download an archive of the files locally
268
268
1. Unzip the archive, then open a terminal and `cd` to the directory you unzipped
269
269
1. Install the dependencies with `npm install`
270
270
1. Run `npm start` to start a local server and follow the prompts to view the code running in a browser
271
271
272
-
If you get stuck, don't let this stop you! Follow along online instead and try a local setup again later.
272
+
আপনি আটকে গেলে, এটি আপনাকে থামাতে দেবেন না! পরিবর্তে online follow করুন এবং পরে আবার একটি local setup চেষ্টা করুন।
273
273
274
274
</Note>
275
275
276
276
## Overview {/*overview*/}
277
277
278
-
Now that you're set up, let's get an overview of React!
278
+
আপনার সেটআপ সম্পূর্ণ হয়েছে, চলুন react সম্পর্কে ধারণা লাভ করি!
279
279
280
-
### Inspecting the starter code {/*inspecting-the-starter-code*/}
Now let's have a look at the files in the starter code.
303
+
এখন starter code-এ উপস্থিত file-গুলোকে দেখে নেওয়া যাক।
303
304
304
305
#### `App.js` {/*appjs*/}
305
306
306
-
The code in `App.js`creates a _component_. In React, a component is a piece of reusable code that represents a part of a user interface. Components are used to render, manage, and update the UI elements in your application. Let's look at the component line by line to see what's going on:
307
+
`App.js`file-এ উপস্থিত code একটি _component_ তৈরী করে| React-এ component হলো পুনরায় ব্যবহারযোগ্য code যা user interface-এর একটি অংশকে নির্দেশ করে| আপনার Application-এর UI elements-গুলোকে render, manage, এবং update করতে components ব্যবহার করা হয়| Component-টির মধ্যে কি হচ্ছে বুঝতে component-টির এক এক করে প্রতিটি লাইন দেখে নেওয়া যাক:
307
308
308
309
```js {1}
309
310
exportdefaultfunctionSquare() {
310
311
return<button className="square">X</button>;
311
312
}
312
313
```
313
314
314
-
The first line defines a function called `Square`. The`export`JavaScript keyword makes this function accessible outside of this file. The `default` keyword tells other files using your code that it's the main function in your file.
315
+
প্রথম লাইনটি `Square` নামক function define করছে| JavaScript-এর`export` keyword-টি এই function-টিকে এই file-এর বাইরে অর্থাৎ অন্য file-এ accessible করে| default কীওয়ার্ডটি অন্যান্য ফাইলগুলিকে আপনার কোডে বলে দেয় যে এটি আপনার ফাইলের main function।
315
316
316
317
```js {2}
317
318
exportdefaultfunctionSquare() {
318
319
return<button className="square">X</button>;
319
320
}
320
321
```
321
322
322
-
The second line returns a button. The`return`JavaScript keyword means whatever comes after is returned as a value to the caller of the function. `<button>`is a*JSX element*. A JSX element is a combination of JavaScript code and HTML tags that describes what you'd like to display. `className="square"`is a button property or*prop* that tells CSS how to style the button.`X`is the text displayed inside of the button and `</button>`closes the JSX element to indicate that any following content shouldn't be placed inside the button.
323
+
দ্বিতীয় লাইনটি একটি button return করে। JavaScript-এর `return` কীওয়ার্ডটি বোঝায় যে এর পরে যা আসবে, তা function caller-এর value হিসাবে return করা হয়। `<button>` হল একটি *JSX element*। JSX element হল JavaScript code এবং HTML tag-গুলির সমন্বয়, যা বর্ণনা করে আপনি প্রদর্শনের জন্য কি দেখাতে চান। `className="square"` হল একটি button property বা *prop*, যা CSS-কে বলে button-টিকে কিভাবে style করতে হবে। `X` হল বাটনের ভিতরে প্রদর্শিত text এবং `</button>` JSX element-টিকে বন্ধ করে, এবং এর থেকে বোঝা যায় যে পরবর্তী কোনো component button-এর ভিতরে রাখা হবে না।
323
324
324
325
#### `styles.css` {/*stylescss*/}
325
326
326
-
Click on the file labeled `styles.css`in the _Files_ section of CodeSandbox. This file defines the styles for your React app. The first two _CSS selectors_ (`*`and`body`) define the style of large parts of your app while the `.square` selector defines the style of any component where the`className` property is set to`square`. In your code, that would match the button from your Square component in the`App.js` file.
327
+
CodeSandbox-এর _Files_ section-এ চিহ্নিত `styles.css`নামক ফাইলটিতে ক্লিক করুন। এই ফাইলটি আপনার React app-এর জন্য styles বর্ণনা করে। প্রথম দুটি _CSS selectors_ (`*`এবং`body`) আপনার অ্যাপের বড় অংশের স্টাইল বর্ণনা করে, যেখানে যেকোনো component-এ যেখানে যেখানে`className` property-টি সেট করা হয়েছে`square`, সেখানকার style `.square` selector দ্বারা বর্ণনা করা হয়। আপনার কোডে, এটি`App.js` file-এর আপনার Square component-এর button-এর style-এর সাথে মিলে যাবে।
327
328
328
329
#### `index.js` {/*indexjs*/}
329
330
330
-
Click on the file labeled `index.js`in the _Files_ section of CodeSandbox. You won't be editing this file during the tutorial but it is the bridge between the component you created in the `App.js`file and the web browser.
331
+
CodeSandbox-এর _Files_ section-এ চিহ্নিত `index.js`নামক ফাইলটিতে ক্লিক করুন। টিউটোরিয়ালের সময়ে আপনি এই ফাইলটি edit করবেন না, কিন্তু এটি আপনার `App.js`ফাইলে তৈরি করা component এবং web browser-এর মধ্যে মধ্যস্থতা করে।
0 commit comments