JavaScript comments can be used to explain JavaScript code, and to make it more readable.
JavaScript comments can also be used to prevent execution, when testing alternative code.
자바스크립트 주석은 자바스크립트 코드를 설명하기 위해서 사용되어질수 있다. 그리고 자바스크립트 주석은 좀더 읽기 쉽게 만들어 준다.
자바스크립트 주석은 대안의 코드를 실행할때, 실행을 예방하기 위해서 사용되어진다.
Single Line Comments
Single line comments start with //.
Any text between // and the end of the line will be ignored by JavaScript (will not be executed).
This example uses a single-line comment before each code line:
싱글 라인 주석
싱글라인 주석은 "//" 로 시작한다.
"//" 안에 있는 어떤 텍스트든지 자바스크립트의 의해서 무시되어진다.
이것은 각라인전에 싱글 주석의 사용의 예이다.
Multi-line Comments
Multi-line comments start with /* and end with */.
Any text between /* and */ will be ignored by JavaScript.
This example uses a multi-line comment (a comment block) to explain the code:
여러줄의 주석
여러줄의 시작은 "/*"로 시작하고 "/*" 로 끝난다.
/* */ 안의 어떤 텍스트든지 자바스크립트의 의해서 무시되어진다.
이것은 코드를 설명하기 위한 멀티라인 주석의 예제이다.
It is most common to use single line comments.
Block comments are often used for formal documentation.
이것은 싱글라인 주석을 사용하기 위한 일반적인 방법이다.
블록 주석은 형식문서?를 위해서 자주 사용되어진다.
Using Comments to Prevent Execution
Using comments to prevent execution of code is suitable for code testing.
Adding // in front of a code line changes the code lines from an executable line to a comment.
This example uses // to prevent execution of one of the code lines:
실행을 막기 위해서 주석 사용하기
코드의 실행을 막기 위해 주석을 사용하는 것은 테스트 코드를 위해서 적합하다.
이예제는 코드 라인의 한줄을 막기 위해서 사용한다.
'영어공부' 카테고리의 다른 글
JavaScript Data Types (0) | 2020.02.12 |
---|---|
JavaScript Variables (0) | 2020.02.12 |
JavaScript Syntax (0) | 2020.01.23 |
JavaScript Statements (0) | 2020.01.23 |
JavaScript Output (0) | 2020.01.23 |
JavaScript comments can be used to explain JavaScript code, and to make it more readable.
JavaScript comments can also be used to prevent execution, when testing alternative code.
자바스크립트 주석은 자바스크립트 코드를 설명하기 위해서 사용되어질수 있다. 그리고 자바스크립트 주석은 좀더 읽기 쉽게 만들어 준다.
자바스크립트 주석은 대안의 코드를 실행할때, 실행을 예방하기 위해서 사용되어진다.
Single Line Comments
Single line comments start with //.
Any text between // and the end of the line will be ignored by JavaScript (will not be executed).
This example uses a single-line comment before each code line:
싱글 라인 주석
싱글라인 주석은 "//" 로 시작한다.
"//" 안에 있는 어떤 텍스트든지 자바스크립트의 의해서 무시되어진다.
이것은 각라인전에 싱글 주석의 사용의 예이다.
Multi-line Comments
Multi-line comments start with /* and end with */.
Any text between /* and */ will be ignored by JavaScript.
This example uses a multi-line comment (a comment block) to explain the code:
여러줄의 주석
여러줄의 시작은 "/*"로 시작하고 "/*" 로 끝난다.
/* */ 안의 어떤 텍스트든지 자바스크립트의 의해서 무시되어진다.
이것은 코드를 설명하기 위한 멀티라인 주석의 예제이다.
It is most common to use single line comments.
Block comments are often used for formal documentation.
이것은 싱글라인 주석을 사용하기 위한 일반적인 방법이다.
블록 주석은 형식문서?를 위해서 자주 사용되어진다.
Using Comments to Prevent Execution
Using comments to prevent execution of code is suitable for code testing.
Adding // in front of a code line changes the code lines from an executable line to a comment.
This example uses // to prevent execution of one of the code lines:
실행을 막기 위해서 주석 사용하기
코드의 실행을 막기 위해 주석을 사용하는 것은 테스트 코드를 위해서 적합하다.
이예제는 코드 라인의 한줄을 막기 위해서 사용한다.
'영어공부' 카테고리의 다른 글
JavaScript Data Types (0) | 2020.02.12 |
---|---|
JavaScript Variables (0) | 2020.02.12 |
JavaScript Syntax (0) | 2020.01.23 |
JavaScript Statements (0) | 2020.01.23 |
JavaScript Output (0) | 2020.01.23 |