Notice
Recent Posts
Tags
- dom event
- express 서버
- css3 selector
- 관계형 데이터 베이스
- requirejs
- mysql
- nodejs
- findindex
- displaytable
- 컨텐츠 중간 위치
- 미들웨어
- ecma script
- ajax
- body-parser
- css3 셀렉터
- Git
- array method
- supervisor
- javascript
- CSS
- 배열 메소드
- IIS 서버
- javascript 이론
- ecmascript method
- 마임타입
- unobtrusive javascript
- database 개념
- 겸손한 자바스크립트
- jQuery
- ecma6
Link
목록ecma6 (1)
Martin`s Work
[ECMAScript] Var, Let, Const 차이점
var 변수 선언과 Let, Const 변수 선언의 차이점 1. 변수 값의 변화기존의 자바스크립트에서는 var를 이용하여 변수를 선언하였다. var로 선언한 변수의 경우 할당되는 값이 유동적으로 변경이 가능하였다. 1234var hello="hello";console.log(hello); //result : hellovar hello="hi";console.log(hello); //result :hics 예를 들어 위의 경우처럼 최초 hello 변수를 선언할 때, 값을 "hello"로 할당을 해준 후, 밑에서 해당 변수의 값을 "hi"로 바꾼다고 하여도, 에러 없이 값이 바뀐다. 하지만 let과 const로 변수를 선언한 경우는 값을 바꿀 수가 없다. 1234let hello="hello";console..
ECMAScript
2017. 6. 17. 13:12