본문 바로가기

프론트엔드 공부

(134)
일반함수와 화살표함수에서 this 정의 차이점 setTimeOut이나 setInterval 같은 함수 사용시 콜백으로 화살표함수 사용하는것이 더 활용서이 뛰어나다 //this 일반함수, 화살표함수 차이 //일반(normal) 함수는 호출 위치에 따라 this 정의 !! //화살표(arrow) 함수는 자신이 선언된 함수 범위 내에서 this 정의 !! function User(name){ this.name = name; } User.prototype.normal = function(){ console.log(this.name); } User.prototype.arrow = () => { console.log(this.name); } //객체생성자함수 const mag = new User('phter'); mag.normal(); //pheter mag..
변수유효범위(variable scope) 변수 유효범위 (variable scope): 변수가 블록 스코프 안에 있거나 값이 할당되기 전에 선언되면 유효범위 밖이라고 볼 수 있다. let, const는 블록레벨의 유효범위를 가진다 고 말한다. (var은 함수레벨의 유효범위를 가진다. ) function scope(){ //console.log(a); if(true){ //console.log(a); let a = 123; console.log(a); } //console.log(a); }
css translateZ hover card flip animation https://codepen.io/fangmin/pen/oNZYbWe?editors=1100 hover translateZ css animation ... codepen.io translateZ의 부모속성에 perspective, transform-style을 지정하면 z 값을 움직일수 있습니다 !
css transform animation https://codepen.io/fangmin/pen/PopGLzp
php mysqli_connect_errno() mysqli :: $ connect_errno - mysqli_connect_errno — 마지막 연결 호출에서 오류 코드를 반환합니다. 참고 : https://www.php.net/manual/en/mysqli.connect-errno.php
highlight 예제(css javascript hover시 width 값이 조정) 원하는 위치에 마우스를 호버시 width 값이 조정되며 따라다니는 highlight입니다. https://codepen.io/fangmin/pen/jOBrdEy?editors=1111
css 변수 js로 핸들링하기 예제 css 변수를 따로 설정하여 js로 핸들링 할수 있는 폰트 변경 예제입니다. https://codepen.io/fangmin/pen/LYWZgdK?editors=1111
css fliter blur animation codepen.io/fangmin/pen/gOmPzVw?editors=1100