Skip to content

Commit fc89e1c

Browse files
Merge pull request #50 from siddiqkaithodu/master
Done
2 parents dcd349e + ba0e82a commit fc89e1c

File tree

1 file changed

+39
-40
lines changed

1 file changed

+39
-40
lines changed

Diff for: 1-js/02-first-steps/01-hello-world/article.md

+39-40
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
# Hello, world!
2+
3+
ട്യൂട്ടോറിയലിന്റെ ഈ ഭാഗം തന്നെ core javascript നെ കുറിച്ചാണ്.
24

3-
This part of the tutorial is about core JavaScript, the language itself.
5+
ഞങ്ങളുടെ സ്ക്രിപ്റ്റുകൾ വർക് ആകണമെങ്കിൽ ഞങ്ങൾക്ക് ഒരു enviornment ആവശ്യമാണ്, കൂടാതെ ഈ പുസ്തകം ഓൺ‌ലൈനിലായതിനാൽ ബ്രൗസർ ഒരു നല്ല ചോയിസാണ്. മറ്റുള്ള (Node.js പോലുള്ളവയിൽ) ശ്രദ്ധ കേന്ദ്രീകരിക്കാൻ നിങ്ങൾ ആഗ്രഹിക്കുന്നുവെങ്കിൽ അതിലൊക്കെ നിങ്ങൾ കഷ്ടപ്പെടാതിരിക്കാൻ ഞങ്ങൾ ബ്രൗസർ കമാൻഡുകൾ (അലേർട്ട് പോലുള്ളവ) ഉപയോഗിക്കുന്നുണ്ട്. ട്യൂട്ടോറിയലിന്റെ [അടുത്ത ഭാഗത്ത്](/ui) ബ്രൗസറിലെ ജാവാസ്ക്രിപ്റ്റിൽ ആയിരിക്കും നമ്മൾ ശ്രദ്ധ കേന്ദ്രീകരിക്കുന്നത്.
46

5-
But we need a working environment to run our scripts and, since this book is online, the browser is a good choice. We'll keep the amount of browser-specific commands (like `alert`) to a minimum so that you don't spend time on them if you plan to concentrate on another environment (like Node.js). We'll focus on JavaScript in the browser in the [next part](/ui) of the tutorial.
7+
അതിനാൽ ആദ്യം, ഒരു വെബ്‌പേജിലേക്ക് നമ്മൾ എങ്ങനെ ഒരു സ്‌ക്രിപ്റ്റ് അറ്റാച്ചു ചെയ്യുന്നുവെന്ന് നോക്കാം. സെർവർ-സൈഡ് ആയിട്ടുള്ളവയ്ക്ക് (Node.js പോലെ), "node my.js" പോലുള്ള ഒരു കമാൻഡ് ഉപയോഗിച്ച് നിങ്ങൾക്ക് എക്സിക്യൂട്ട് ചെയ്യാൻ കഴിയുന്നതാണ്.
68

7-
So first, let's see how we attach a script to a webpage. For server-side environments (like Node.js), you can execute the script with a command like `"node my.js"`.
89

10+
## "script" ടാഗ്
911

10-
## The "script" tag
12+
HTML document ൽ `<script>` ടാഗ് ഉപയോഗിച്ച് എവിടെ വേണമെങ്കിലും നമുക്ക് javascript പ്രോഗ്രാം ചെയ്യാവുന്നതാണ്.
1113

12-
JavaScript programs can be inserted almost anywhere into an HTML document using the `<script>` tag.
13-
14-
For instance:
14+
ഉദാഹരണത്തിന്:
1515

1616
```html run height=100
1717
<!DOCTYPE HTML>
@@ -35,53 +35,53 @@ For instance:
3535
```
3636

3737
```online
38-
You can run the example by clicking the "Play" button in the right-top corner of the box above.
38+
ഈ തന്നിരിക്കുന്ന ഉദാഹരണങ്ങൾ എല്ലാം run ചെയ്തു നോക്കുവാനായി ആ ബോക്സിന്റെ മുകൾ ഭാഗത്ത് വലത് വശത്തുള്ള "Play" ബട്ടണിൽ ഞെക്കിയാൽ മതിയാകും.
3939
```
4040

41-
The `<script>` tag contains JavaScript code which is automatically executed when the browser processes the tag.
41+
`<script>` ടാഗിൽ ഉള്ള javascript കോഡുകളെല്ലാം ബ്രൗസർ <script> കാണുന്ന സമയത്തു തന്നെ execute ചെയ്യും.
4242

4343

44-
## Modern markup
44+
## പുതിയ markupകൾ
4545

46-
The `<script>` tag has a few attributes that are rarely used nowadays but can still be found in old code:
46+
`<script>` tag ന് പണ്ട് ധാരാളമായി ഉപയോഗിച്ചിരുന്നതും ഇപ്പോൾ ചുരുക്കമായി ഉപയോഗിക്കുന്നതുമായ കുറച്ചു attributes ഉണ്ട്:
4747

48-
The `type` attribute: <code>&lt;script <u>type</u>=...&gt;</code>
49-
: The old HTML standard, HTML4, required a script to have a `type`. Usually it was `type="text/javascript"`. It's not required anymore. Also, the modern HTML standard totally changed the meaning of this attribute. Now, it can be used for JavaScript modules. But that's an advanced topic, we'll talk about modules in another part of the tutorial.
48+
`type` attribute: <code>&lt;script <u>type</u>=...&gt;</code>
49+
: പഴയ HTML standard ആയ, HTML4 ന്, `type` ൽ ഉപയോഗിക്കാനായി ഒരു script വേണമായിരുന്നു. സാധാരണ ഇത് `type="text/javascript"` ആയിരുന്നു. ഇപ്പോൾ അതിന്റെ ആവശ്യം ഇല്ല. മാത്രമല്ല ,പുതിയ HTML standard ഈ attribute ന്റെ അർഥo തന്നെ മാറ്റി. ഇപ്പോൾ, അത് JavaScript modules ന് വേണ്ടിയും ഉപയോഗിക്കാം. പക്ഷെ അതൊരു advanced topic ആണ്, നമ്മൾ modules നെ കുറിച്ചു പിന്നീട് നോക്കുന്നതാണ് .
5050

51-
The `language` attribute: <code>&lt;script <u>language</u>=...&gt;</code>
52-
: This attribute was meant to show the language of the script. This attribute no longer makes sense because JavaScript is the default language. There is no need to use it.
51+
`language` attribute: <code>&lt;script <u>language</u>=...&gt;</code>
52+
: script ന്റെ language നെ കാണിക്കാനായിരുന്നു ഈ attribute ഉപയോഗിച്ചിരുന്നത്. JavaScript തന്നെ default language ആയതു കൊണ്ട് ഇപ്പോൾ ഈ attribute ഇട്ടിട്ടും വലിയ കാര്യമൊന്നും ഇല്ല. അത് ഉപയോഗിക്കേണ്ട ആവശ്യമേ നമുക്കില്ല.
5353

54-
Comments before and after scripts.
55-
: In really ancient books and guides, you may find comments inside `<script>` tags, like this:
54+
scripts ന് മുൻപും ശേഷവുമുള്ള comment കൾ.
55+
: പണ്ടത്തെ ബുക്കുകളിലും ഗൈഡിലുമെല്ലാം, നമുക്ക് `<script>` ന്റെ അകത്തു ഇതുപോലെ comments കാണാൻ സാധിക്കും:
5656

5757
```html no-beautify
5858
<script type="text/javascript"><!--
5959
...
6060
//--></script>
6161
```
6262

63-
This trick isn't used in modern JavaScript. These comments hide JavaScript code from old browsers that didn't know how to process the `<script>` tag. Since browsers released in the last 15 years don't have this issue, this kind of comment can help you identify really old code.
63+
ഈ ട്രിക്‌ ഇപ്പോഴത്തെ JavaScript ൽ ഇല്ല. ഈ commentsകൾ '<script>' tag സപ്പോർട്ട് ആകാത്ത പഴയ ചില browser കളിൽ javascript നെ മറച്ചു വെക്കാനാണ് ഉപയോഗിച്ചിരുന്നത്. കഴിഞ്ഞ 15 വർഷമായ് റിലീസ് ആയ browsers ന് ഈ പ്രശ്നം ഇല്ലാത്തതു കൊണ്ടു തന്നെ, ഇത്തരം comment കൾ പഴയ code നെ തിരിച്ചറിയാൻ നമ്മളെ സഹായിക്കും.
6464

6565

66-
## External scripts
66+
## പുറത്തു നിന്നുള്ള script കൾ
6767

68-
If we have a lot of JavaScript code, we can put it into a separate file.
68+
നമുക്ക് ഒരുപാട് JavaScript code ഉണ്ടെങ്കിൽ, നമുക്കത് വേറൊരു ഫയലിലോട്ടു ഇടാവുന്നതാണ്.
6969

70-
Script files are attached to HTML with the `src` attribute:
70+
HTML ൽ script ഫയലുകൾ ഇടുന്നത് `src` എന്ന attribute ഉപയോഗിച്ചാണ്:
7171

7272
```html
7373
<script src="/path/to/script.js"></script>
7474
```
7575

76-
Here, `/path/to/script.js` is an absolute path to the script from the site root. One can also provide a relative path from the current page. For instance, `src="script.js"` would mean a file `"script.js"` in the current folder.
76+
ഇവിടെ, `/path/to/script.js` root ൽ നിന്നും script ലേക്ക് നേരിട്ടുള്ള path ആണ്(absolute). വേണമെങ്കിൽ നമുക്ക് ഇപ്പോഴത്തെ പേജിൽ നിന്നും path(relative) കൊടുക്കാവുന്നതാണ്. ഉദാഹരണത്തിന്, `src="script.js"` അർത്ഥമാക്കുന്നത്‌ `"script.js"` ഇപ്പോഴുള്ള ഫോൾഡറിൽ തന്നെയാണെന്നാണ്.
7777

78-
We can give a full URL as well. For instance:
78+
നമുക്ക് വേണമെങ്കിൽ പൂർണമായ URL ഉം കൊടുക്കാം. ഉദാഹരണത്തിന്:
7979

8080
```html
8181
<script src="https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.17.11/lodash.js"></script>
8282
```
8383

84-
To attach several scripts, use multiple tags:
84+
ഒന്നിൽ കൂടുതൽ script ഉപയോഗിക്കാൻ, വേറെ വേറെ tags ഉപയോഗിക്കുക:
8585

8686
```html
8787
<script src="/js/script1.js"></script>
@@ -90,30 +90,29 @@ To attach several scripts, use multiple tags:
9090
```
9191

9292
```smart
93-
As a rule, only the simplest scripts are put into HTML. More complex ones reside in separate files.
93+
നിയമം അനുസരിച്ച്, ചെറിയ script കൽ മാത്രമേ HTML ഇൽ ഇടാറുള്ളൂ. ബുദ്ധിമുട്ടേറിയ script കൽ വേറെ ഫയലുകളിലായിട്ടാണ് സൂക്ഷിക്കുന്നത്.
9494
95-
The benefit of a separate file is that the browser will download it and store it in its [cache](https://en.wikipedia.org/wiki/Web_cache).
95+
വേറെ വേറെ ഫയലുകൾ ഉപയോഗിക്കുകയാണെങ്കിൽ ബ്രൗസർ അത് ഡൌൺലോഡ് ചെയ്‌ത് അതിന്റെ [cache](https://en.wikipedia.org/wiki/Web_cache)ൽ സൂക്ഷിക്കും.
9696
97-
Other pages that reference the same script will take it from the cache instead of downloading it, so the file is actually downloaded only once.
97+
ഒരേ script ഉപയോഗിക്കുന്ന മറ്റു പേജുകൾ വീണ്ടും script ഡൌൺലോഡ് ചെയ്യാതെ cache ൽ നിന്നും എടുക്കും, അതായത് ഒരു ഫയൽ ഒരു തവണ മാത്രമേ download ആകുകയുള്ളൂ.
9898
99-
That reduces traffic and makes pages faster.
99+
ഇത് traffic കുറക്കുകയും പേജ് പെട്ടെന്ന് ലോഡ് ആകുവാനും സഹായിക്കുന്നു.
100100
```
101101

102-
````warn header="If `src` is set, the script content is ignored."
103-
A single `<script>` tag can't have both the `src` attribute and code inside.
102+
````warn header=" `src` ഉണ്ടെങ്കിൽ, script ലുള്ള കോഡുകൾ അവഗണിക്കപ്പെടുന്നതാണ്."
103+
ഒരു `<script>` tag ന് ഒരേ സമയം `src` attribute ഉം അതിന്റെ അകത്തു കോഡും വരാൻ പാടുള്ളതല്ല.
104104

105-
This won't work:
105+
ഇതു വർക്ക് ആകില്ല:
106106

107107
```html
108108
<script *!*src*/!*="file.js">
109-
alert(1); // the content is ignored, because src is set
109+
alert(1); // , src ഉള്ളത് കൊണ്ട്, അകത്തുള്ള കോഡ് അവഗണിക്കപ്പെടുന്നതാണ്
110110
</script>
111111
```
112112

113-
We must choose either an external `<script src="…">` or a regular `<script>` with code.
114-
115-
The example above can be split into two scripts to work:
113+
നമ്മൾ ഒരു external `<script src="…">` അല്ലെങ്കിൽ regular `<script>` മാത്രമേ code ന്റെ കൂടെ ഉപയോഗിക്കാൻ പാടുള്ളൂ.
116114

115+
മുകളിലുള്ള ഉദാഹരണം വർക്ക് ആകാൻ വേണ്ടി നമുക്ക് അതിനെ രണ്ടു script ആയിട്ടു ഭാഗിക്കാം:
117116
```html
118117
<script src="file.js"></script>
119118
<script>
@@ -122,11 +121,11 @@ The example above can be split into two scripts to work:
122121
```
123122
````
124123
125-
## Summary
124+
## സംഗ്രഹം
126125
127-
- We can use a `<script>` tag to add JavaScript code to a page.
128-
- The `type` and `language` attributes are not required.
129-
- A script in an external file can be inserted with `<script src="path/to/script.js"></script>`.
126+
- JavaScript കോഡ് ഒരു പേജിൽ ചേർക്കാൻ നമുക്ക് `<script>` tag ഉപയോഗിക്കാം.
127+
- `type` ഉം `language` attribute കളും വേണമെന്നില്ല.
128+
- പുറത്തു നിന്നുള്ള ഒരു script ഫയൽ നമുക്ക് `<script src="path/to/script.js"></script>` ഉപയോഗിച്ച് ചേർക്കാൻ കഴിയുന്നതാണ്.
130129
131130
132-
There is much more to learn about browser scripts and their interaction with the webpage. But let's keep in mind that this part of the tutorial is devoted to the JavaScript language, so we shouldn't distract ourselves with browser-specific implementations of it. We'll be using the browser as a way to run JavaScript, which is very convenient for online reading, but only one of many.
131+
ബ്രൗസർ script കളെ കുറിച്ചും അത് വെബ്‌പ്പേജുകളുമായി ഇടപെടുന്നതിനെ കുറിച്ചും ഒരുപാട് അറിയാനുണ്ട്. ഈ ഭാഗം നമ്മൾ JavaScript ന് മാത്രമായി മാറ്റിവെച്ചിട്ടുള്ള കാര്യം ഓർക്കുക, അതുകൊണ്ട് നമ്മൾ ബ്രൌസർ ലോട്ട് ശ്രദ്ധ തിരിക്കേണ്ട ആവശ്യം ഇല്ല. JavaScript ഉപയോഗിക്കാൻ മാത്രമാണ് നമ്മൾ ബ്രൗസർ ഉപയോഗിക്കുന്നത്, മാത്രമല്ല നമുക്കതിൽ വായിക്കാൻ എളുപ്പവുമാണ്.

0 commit comments

Comments
 (0)